instance method
attribute_missing
Ruby on Rails 7.1.6
Since v3.2.22.5Signature
attribute_missing(match, *args, &block)
attribute_missing is like method_missing, but for attributes. When method_missing is called we check to see if there is a matching attribute method. If so, we tell attribute_missing to dispatch the attribute. This method can be overloaded to customize the behavior.
Parameters
-
matchreq -
argsrest -
blockblock
Source
# File activemodel/lib/active_model/attribute_methods.rb, line 520
def attribute_missing(match, *args, &block)
__send__(match.proxy_target, match.attr_name, *args, &block)
end
Defined in activemodel/lib/active_model/attribute_methods.rb line 520
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActiveModel::AttributeMethods