docs: add documentation for various classes in app/logical.
This commit is contained in:
@@ -1,3 +1,9 @@
|
||||
# Define a custom validator for user names.
|
||||
#
|
||||
# @example
|
||||
# validates :name, user_name: true
|
||||
#
|
||||
# @see https://guides.rubyonrails.org/active_record_validations.html#custom-validators
|
||||
class UserNameValidator < ActiveModel::EachValidator
|
||||
def validate_each(rec, attr, value)
|
||||
name = value
|
||||
|
||||
Reference in New Issue
Block a user