From 9e124e1b3e3f3cd06db7ac58c3aefca3382cd870 Mon Sep 17 00:00:00 2001 From: Luke Kanies Date: Thu, 10 Feb 2011 14:55:23 -0800 Subject: Fixing rendering to support arrays This isn't 100% - it will probably only work for Yaml and JSON - but it's a good start. Signed-off-by: Luke Kanies --- lib/puppet/application/data_baseclass.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lib/puppet/application') diff --git a/lib/puppet/application/data_baseclass.rb b/lib/puppet/application/data_baseclass.rb index e67b1b368..8da624c60 100644 --- a/lib/puppet/application/data_baseclass.rb +++ b/lib/puppet/application/data_baseclass.rb @@ -47,7 +47,8 @@ class Puppet::Application::DataBaseclass < Puppet::Application def main # Call the method associated with the provided action (e.g., 'find'). result = interface.send(verb, name, *arguments) - puts result.render(format) + render_method = Puppet::Network::FormatHandler.format(format).render_method + puts result.send(render_method) end def setup -- cgit