lib/anyway/ext/deep_freeze.rb in anyway_config-1.4.4 vs lib/anyway/ext/deep_freeze.rb in anyway_config-2.0.0.pre
- old
+ new
@@ -20,9 +20,14 @@
value.deep_freeze if value.is_a?(::Hash) || value.is_a?(::Array)
end
end
end
+ begin
+ require "active_support/core_ext/hash/indifferent_access"
+ rescue LoadError
+ end
+
if defined?(::ActiveSupport::HashWithIndifferentAccess)
refine ::ActiveSupport::HashWithIndifferentAccess do
def deep_freeze
freeze
each_value do |value|