Sha256: 1c44f4f94e6d2ad344ebfa30468eecd7ed3f3fca3c2fe2f2a72979fb4a48b384
Contents?: true
Size: 236 Bytes
Versions: 5
Compression:
Stored size: 236 Bytes
Contents
class RequiredValidation < Validation def self.validate(params, field, name, value, record, errors) errors[field.name] << new(params) if (value.blank? && !value.is_a?(FalseClass)) end def describe "is required" end end
Version data entries
5 entries across 5 versions & 1 rubygems