mirror of
https://github.com/inspec/inspec
synced 2024-11-15 09:27:20 +00:00
bugfix: return nil on file content read errors
Signed-off-by: Dominik Richter <dominik.richter@gmail.com>
This commit is contained in:
parent
b04cfc688d
commit
e0b89e6ae2
1 changed files with 2 additions and 0 deletions
|
@ -48,6 +48,8 @@ module Vulcano::Backends
|
|||
class File < LinuxFile
|
||||
def content
|
||||
@content ||= ::File.read(@path)
|
||||
rescue StandardError => _
|
||||
nil
|
||||
end
|
||||
|
||||
%w{
|
||||
|
|
Loading…
Reference in a new issue