Method: ActiveModel::Validations::AcceptanceValidator::LazilyDefineAttributes#matches?
- Defined in:
- activemodel/lib/active_model/validations/acceptance.rb
#matches?(method_name) ⇒ Boolean
51 52 53 54 |
# File 'activemodel/lib/active_model/validations/acceptance.rb', line 51 def matches?(method_name) attr_name = method_name.to_s.chomp("=") attributes.any? { |name| name == attr_name } end |