lib/puppet/util/zaml.rb in puppet-2.6.2 vs lib/puppet/util/zaml.rb in puppet-2.6.3

- old
+ new

@@ -118,10 +118,13 @@ class Object def to_yaml_properties instance_variables.sort # Default YAML behavior end + def yaml_property_munge(x) + x + end def zamlized_class_name(root) cls = self.class "!ruby/#{root.name.downcase}#{cls == root ? '' : ":#{cls.respond_to?(:name) ? cls.name : cls}"}" end def to_zaml(z) @@ -134,10 +137,10 @@ else instance_variables.each { |v| z.nl v[1..-1].to_zaml(z) # Remove leading '@' z.emit(': ') - instance_variable_get(v).to_zaml(z) + yaml_property_munge(instance_variable_get(v)).to_zaml(z) } end } } end