bolt-modules/file/lib/puppet/functions/file/read.rb in bolt-1.21.0 vs bolt-modules/file/lib/puppet/functions/file/read.rb in bolt-1.22.0
- old
+ new
@@ -12,9 +12,10 @@
required_param 'String', :filename
return_type 'String'
end
def read(scope, filename)
+ Puppet.lookup(:bolt_executor) {}&.report_function_call(self.class.name)
found = Puppet::Parser::Files.find_file(filename, scope.compiler.environment)
unless found && Puppet::FileSystem.exist?(found)
raise Puppet::ParseErrorWithIssue.from_issue_and_stack(
Puppet::Pops::Issues::NO_SUCH_FILE_OR_DIRECTORY, file: filename
)