method
new
v4.0.2 -
Show latest stable
- Class:
ActiveRecord::DynamicMatchers::Method
new(model, name)public
No documentation available.
# File activerecord/lib/active_record/dynamic_matchers.rb, line 52
def initialize(model, name)
@model = model
@name = name.to_s
@attribute_names = @name.match(self.class.pattern)[1].split('_and_')
@attribute_names.map! { |n| @model.attribute_aliases[n] || n }
end