bolt-modules/boltlib/lib/puppet/functions/run_command.rb in bolt-2.1.0 vs bolt-modules/boltlib/lib/puppet/functions/run_command.rb in bolt-2.2.0
- old
+ new
@@ -49,10 +49,10 @@
unless Puppet[:tasks]
raise Puppet::ParseErrorWithIssue
.from_issue_and_stack(Bolt::PAL::Issues::PLAN_OPERATION_NOT_SUPPORTED_WHEN_COMPILING, action: 'run_command')
end
- options = options.map { |k, v| [k.sub(/^_/, '').to_sym, v] }.to_h
+ options = options.transform_keys { |k| k.sub(/^_/, '').to_sym }
options[:description] = description if description
executor = Puppet.lookup(:bolt_executor)
inventory = Puppet.lookup(:bolt_inventory)