From dda32647b4c11ecb352e469088f2438835ff99d7 Mon Sep 17 00:00:00 2001 From: Daniel Pittman Date: Wed, 4 May 2011 10:40:55 -0700 Subject: (#7353) Note the :for_humans compatibility issue. Where we need special support for :for_humans as an alias for :console, call it out in comments. This makes it clear to someone who wonders why what the actual underlying purpose of the whole thing is. Reviewed-By: Jacob Helwig --- lib/puppet/interface/action_builder.rb | 2 ++ 1 file changed, 2 insertions(+) (limited to 'lib/puppet/interface') diff --git a/lib/puppet/interface/action_builder.rb b/lib/puppet/interface/action_builder.rb index 0bf4f1408..16305530a 100644 --- a/lib/puppet/interface/action_builder.rb +++ b/lib/puppet/interface/action_builder.rb @@ -38,6 +38,8 @@ class Puppet::Interface::ActionBuilder def render_as(value = nil) value.nil? and raise ArgumentError, "You must give a rendering format to render_as" + # :for_humans is a compatibility alias for :console, but since we shipped + # it in 2.7.0rc1 we need to support it ongoing. --daniel 2011-05-04 formats = Puppet::Network::FormatHandler.formats << :for_humans unless formats.include? value raise ArgumentError, "#{value.inspect} is not a valid rendering format: #{formats.sort.join(", ")}" -- cgit