diff options
author | Adrien Thebo <git@somethingsinistral.net> | 2013-09-17 11:35:57 -0700 |
---|---|---|
committer | Adrien Thebo <git@somethingsinistral.net> | 2013-09-17 11:35:57 -0700 |
commit | 1011670bade47441346e518506673016b6097bcd (patch) | |
tree | 533c5dd8d966359c155ebac7ac34f99554e67cf1 /lib/puppet/parser | |
parent | f7f70fe9ee00c5d5aa27d8060b200bf91ddd2413 (diff) | |
parent | 51d96088c1d6bde8dae511d6a93bc6775e716f60 (diff) |
Merge pull request #182 from lmello/fix_bug_20681_delete_values
delete_values() fix bug #20681.
Diffstat (limited to 'lib/puppet/parser')
-rw-r--r-- | lib/puppet/parser/functions/delete_values.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/puppet/parser/functions/delete_values.rb b/lib/puppet/parser/functions/delete_values.rb index 17b9d37..ca8eef5 100644 --- a/lib/puppet/parser/functions/delete_values.rb +++ b/lib/puppet/parser/functions/delete_values.rb @@ -21,6 +21,6 @@ Would return: {'a'=>'A','c'=>'C','B'=>'D'} raise(TypeError, "delete_values(): First argument must be a Hash. " + \ "Given an argument of class #{hash.class}.") end - hash.delete_if { |key, val| item == val } + hash.dup.delete_if { |key, val| item == val } end end |