Sha256: 117553abc177739b651d85b8c47e880dd71cb46b4dbb0cb5d2d730e1e1cbc673
Contents?: true
Size: 350 Bytes
Versions: 6
Compression:
Stored size: 350 Bytes
Contents
# frozen_string_literal: true module ActiveModel module Validations class UsernameValidator < SubdomainValidator end module ClassMethods def validates_username(*attr_names) options = _merge_attributes(attr_names).merge(error_name: :username) validates_with UsernameValidator, options end end end end
Version data entries
6 entries across 6 versions & 1 rubygems