Module: SoftValidation::ClassMethods

Defined in:
lib/soft_validation.rb

Instance Method Summary collapse

Instance Method Details

#soft_validate(method, options = {}) ⇒ Object



245
246
247
248
249
250
251
252
# File 'lib/soft_validation.rb', line 245

def soft_validate(method, options = {})
  self.soft_validation_methods[:all] << method 
  if options[:set]
    self.soft_validation_methods[options[:set]] ||= []
    self.soft_validation_methods[options[:set]] << method 
  end
  true
end