vendored/puppet/lib/hiera_puppet.rb in bolt-0.15.0 vs vendored/puppet/lib/hiera_puppet.rb in bolt-0.16.0

- old
+ new

@@ -9,11 +9,11 @@ scope = Hiera::Scope.new(scope) answer = hiera.lookup(key, default, scope, override, resolution_type) if answer.nil? - raise(Puppet::ParseError, "Could not find data item #{key} in any Hiera data file and no default supplied") + raise Puppet::ParseError, _("Could not find data item %{key} in any Hiera data file and no default supplied") % { key: key } end answer end @@ -36,11 +36,11 @@ if args[0].is_a?(Array) args = args[0] end if args.empty? - raise(Puppet::ParseError, "Please supply a parameter to perform a Hiera lookup") + raise Puppet::ParseError, _("Please supply a parameter to perform a Hiera lookup") end key = args[0] default = args[1] override = args[2] @@ -69,10 +69,10 @@ def hiera_config_file hiera_config = Puppet.settings[:hiera_config] if Puppet::FileSystem.exist?(hiera_config) hiera_config else - Puppet.warning "Config file #{hiera_config} not found, using Hiera defaults" + Puppet.warning _("Config file %{hiera_config} not found, using Hiera defaults") % { hiera_config: hiera_config } nil end end end