diff options
author | Gannon McGibbon <gannon.mcgibbon@gmail.com> | 2019-04-12 16:08:12 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-04-12 16:08:12 -0400 |
commit | 4e342c36b55c27c8b378aedd8fa7acb71e37609f (patch) | |
tree | 4f7d1eae0d9592c3553b402a0823bc948b20f2d0 /activemodel/lib | |
parent | 713f62430a42294dcb156cc8f38b41509a60d7a6 (diff) | |
parent | 63b5bdea517c47b50c909c1be128d26d598db9a5 (diff) | |
download | rails-4e342c36b55c27c8b378aedd8fa7acb71e37609f.tar.gz rails-4e342c36b55c27c8b378aedd8fa7acb71e37609f.tar.bz2 rails-4e342c36b55c27c8b378aedd8fa7acb71e37609f.zip |
Merge pull request #35955 from shioyama/remove_method_name_from_attribute_method_match
Remove unused method_name from AttributeMethodMatch
Diffstat (limited to 'activemodel/lib')
-rw-r--r-- | activemodel/lib/active_model/attribute_methods.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/activemodel/lib/active_model/attribute_methods.rb b/activemodel/lib/active_model/attribute_methods.rb index afeee03d4f..d87528f789 100644 --- a/activemodel/lib/active_model/attribute_methods.rb +++ b/activemodel/lib/active_model/attribute_methods.rb @@ -387,7 +387,7 @@ module ActiveModel class AttributeMethodMatcher #:nodoc: attr_reader :prefix, :suffix, :method_missing_target - AttributeMethodMatch = Struct.new(:target, :attr_name, :method_name) + AttributeMethodMatch = Struct.new(:target, :attr_name) def initialize(options = {}) @prefix, @suffix = options.fetch(:prefix, ""), options.fetch(:suffix, "") @@ -398,7 +398,7 @@ module ActiveModel def match(method_name) if @regex =~ method_name - AttributeMethodMatch.new(method_missing_target, $1, method_name) + AttributeMethodMatch.new(method_missing_target, $1) end end |