class Quby::TypeValidator
Public Instance Methods
validate_each(record, attribute, value)
click to toggle source
# File lib/quby/type_validator.rb, line 6 def validate_each(record, attribute, value) return if value.is_a? options[:is_a] record.errors.add(attribute, "Is not of type #{options[:is_a]}") end