diff --git a/activesupport/lib/active_support/ordered_hash.rb b/activesupport/lib/active_support/ordered_hash.rb index dfc3f01fa2..7f148dc853 100644 --- a/activesupport/lib/active_support/ordered_hash.rb +++ b/activesupport/lib/active_support/ordered_hash.rb @@ -79,7 +79,7 @@ module ActiveSupport end def []=(key, value) - @keys << key if !has_key?(key) + @keys << key unless has_key?(key) super end