From 6dbfc6773472c8a503b2a9ab2b9a4c6af6bc4eef Mon Sep 17 00:00:00 2001 From: Akira Matsuda Date: Wed, 31 Jul 2019 09:51:41 +0900 Subject: Accessing ivar with Symbols might be just a very little bit better than with fstrings --- activemodel/lib/active_model/errors.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'activemodel') diff --git a/activemodel/lib/active_model/errors.rb b/activemodel/lib/active_model/errors.rb index 42c004ce31..c91ac69603 100644 --- a/activemodel/lib/active_model/errors.rb +++ b/activemodel/lib/active_model/errors.rb @@ -100,7 +100,7 @@ module ActiveModel def copy!(other) # :nodoc: @errors = other.errors.deep_dup @errors.each { |error| - error.instance_variable_set("@base", @base) + error.instance_variable_set(:@base, @base) } end -- cgit v1.2.3