diff options
author | Matthew Draper <matthew@trebex.net> | 2017-07-02 01:07:08 +0930 |
---|---|---|
committer | Matthew Draper <matthew@trebex.net> | 2017-07-02 01:07:12 +0930 |
commit | afb66a5a598ce4ac74ad84b125a5abf046dcf5aa (patch) | |
tree | 33d690f194f243a3fb63e69f8393ff46cc396249 /activesupport/lib/active_support/xml_mini/libxmlsax.rb | |
parent | 9ecdcac16795854bd02f1addcf75b84d34bbdf86 (diff) | |
parent | 3d453b409d037a056d0bcd636a2e020cc7cef4a8 (diff) | |
download | rails-afb66a5a598ce4ac74ad84b125a5abf046dcf5aa.tar.gz rails-afb66a5a598ce4ac74ad84b125a5abf046dcf5aa.tar.bz2 rails-afb66a5a598ce4ac74ad84b125a5abf046dcf5aa.zip |
Merge pull request #29506 from pat/frozen-string-literals
Make ActiveSupport frozen-string-literal friendly.
Diffstat (limited to 'activesupport/lib/active_support/xml_mini/libxmlsax.rb')
-rw-r--r-- | activesupport/lib/active_support/xml_mini/libxmlsax.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/activesupport/lib/active_support/xml_mini/libxmlsax.rb b/activesupport/lib/active_support/xml_mini/libxmlsax.rb index f3d485da2f..b1b5517414 100644 --- a/activesupport/lib/active_support/xml_mini/libxmlsax.rb +++ b/activesupport/lib/active_support/xml_mini/libxmlsax.rb @@ -21,7 +21,7 @@ module ActiveSupport end def on_start_document - @hash = { CONTENT_KEY => "" } + @hash = { CONTENT_KEY => "".dup } @hash_stack = [@hash] end @@ -31,7 +31,7 @@ module ActiveSupport end def on_start_element(name, attrs = {}) - new_hash = { CONTENT_KEY => "" }.merge!(attrs) + new_hash = { CONTENT_KEY => "".dup }.merge!(attrs) new_hash[HASH_SIZE_KEY] = new_hash.size + 1 case current_hash[name] |