From b979e34b05652cbfb4e9ca7adc29ba9a01081437 Mon Sep 17 00:00:00 2001 From: Simon Beirnaert Date: Tue, 8 Nov 2016 08:37:12 +0100 Subject: (MODULES-3829) Use .dup to duplicate classes for modification. This function otherwise fails during `puppet preview` on Puppet 3.8.X systems. --- lib/puppet/parser/functions/ensure_resources.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/puppet/parser/functions/ensure_resources.rb b/lib/puppet/parser/functions/ensure_resources.rb index 30d57a8..b3c51e6 100644 --- a/lib/puppet/parser/functions/ensure_resources.rb +++ b/lib/puppet/parser/functions/ensure_resources.rb @@ -36,7 +36,7 @@ ENDOFDOC params ||= {} if title.is_a?(Hash) - resource_hash = Hash(title) + resource_hash = title.dup resources = resource_hash.keys Puppet::Parser::Functions.function(:ensure_resource) -- cgit v1.2.3