]> gitweb.fluxo.info Git - puppet-stdlib.git/commitdiff
(#10285) Refactor json to use pson instead.
authorNan Liu <nan@puppetlabs.com>
Tue, 25 Oct 2011 22:54:47 +0000 (15:54 -0700)
committerNan Liu <nan@puppetlabs.com>
Tue, 25 Oct 2011 22:54:47 +0000 (15:54 -0700)
Remove json requirement since puppet already provides pson which is
equivalent.

lib/puppet/parser/functions/parsejson.rb

index cf3b12c5c1315c22e94b2e7668b4eb60363d6e7d..a9a16a4524bce8cae03456ed6217f818c61911d0 100644 (file)
@@ -15,11 +15,9 @@ structure.
     end
 
     json = arguments[0]
-    
-    require 'json'
-
-    JSON.load(json)
 
+    # PSON is natively available in puppet
+    PSON.load(json)
   end
 end