diff options
author | Alex Cline <acline@us.ibm.com> | 2013-05-06 13:52:57 -0400 |
---|---|---|
committer | Alex Cline <acline@us.ibm.com> | 2013-05-06 13:52:57 -0400 |
commit | de253db5648c0aa15e7fcead9755488e9d8642fc (patch) | |
tree | 702466e7553bbeaaf7bbf4d8b3762d5c4b082efa | |
parent | e08734af5a38cb9ad4bc2323104a1a8a76019bb8 (diff) | |
download | puppet-stdlib-de253db5648c0aa15e7fcead9755488e9d8642fc.tar.gz puppet-stdlib-de253db5648c0aa15e7fcead9755488e9d8642fc.tar.bz2 |
Changed str-to-array conversion and removed abbreviation.
-rw-r--r-- | lib/puppet/parser/functions/ensure_resource.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/puppet/parser/functions/ensure_resource.rb b/lib/puppet/parser/functions/ensure_resource.rb index 8ede967..36c423a 100644 --- a/lib/puppet/parser/functions/ensure_resource.rb +++ b/lib/puppet/parser/functions/ensure_resource.rb @@ -31,12 +31,12 @@ ENDOFDOC raise(ArgumentError, 'Must specify a title') unless title params ||= {} - items = title.kind_of?(Array) ? title : [].push(title) + items = title.kind_of?(Array) ? title : [title] items.each do |item| Puppet::Parser::Functions.function(:defined_with_params) if function_defined_with_params(["#{type}[#{item}]", params]) - Puppet.debug("Resource #{type}[#{item}] not created b/c it already exists") + Puppet.debug("Resource #{type}[#{item}] not created because it already exists") else Puppet::Parser::Functions.function(:create_resources) function_create_resources([type.capitalize, { item => params }]) |