diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2015-07-09 19:14:22 -0700 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2015-07-10 14:19:10 -0700 |
commit | 79ab81266327e4ee59810c8556091c6f4ee9cfe5 (patch) | |
tree | 7353d6a3f7dcb3b9c6b332dcd91f9c24a5bf8af5 /actionpack | |
parent | c546a2b045600b6d700140adf2a4df666d6e08ce (diff) | |
download | rails-79ab81266327e4ee59810c8556091c6f4ee9cfe5.tar.gz rails-79ab81266327e4ee59810c8556091c6f4ee9cfe5.tar.bz2 rails-79ab81266327e4ee59810c8556091c6f4ee9cfe5.zip |
remove param dup'ing logic
since we are serializing parameters, we don't need to do all the dup
checks on each object.
Diffstat (limited to 'actionpack')
-rw-r--r-- | actionpack/lib/action_controller/test_case.rb | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/actionpack/lib/action_controller/test_case.rb b/actionpack/lib/action_controller/test_case.rb index 819ebedc0f..8ae2ccca39 100644 --- a/actionpack/lib/action_controller/test_case.rb +++ b/actionpack/lib/action_controller/test_case.rb @@ -48,14 +48,6 @@ module ActionController non_path_parameters = {}.with_indifferent_access parameters.each do |key, value| - if value.is_a?(Array) && (value.frozen? || value.any?(&:frozen?)) - value = value.map{ |v| v.duplicable? ? v.dup : v } - elsif value.is_a?(Hash) && (value.frozen? || value.any?{ |k,v| v.frozen? }) - value = Hash[value.map{ |k,v| [k, v.duplicable? ? v.dup : v] }] - elsif value.frozen? && value.duplicable? - value = value.dup - end - if extra_keys.include?(key) || key == :action || key == :controller non_path_parameters[key] = value else |