mirror of
https://github.com/inspec/inspec
synced 2024-11-22 12:43:07 +00:00
CFINSPEC-274: Handle case of nil or error resource_id
Signed-off-by: Sonu Saha <sonu.saha@progress.com>
This commit is contained in:
parent
60f80b9f97
commit
51d3717885
3 changed files with 3 additions and 3 deletions
|
@ -186,7 +186,7 @@ module Inspec::Resources
|
|||
end
|
||||
|
||||
def resource_id
|
||||
@opts[:filepath] || subject.CN
|
||||
@opts[:filepath] || subject.CN || "x509 Certificate"
|
||||
end
|
||||
|
||||
def to_s
|
||||
|
|
|
@ -39,7 +39,7 @@ module Inspec::Resources
|
|||
end
|
||||
|
||||
def resource_id
|
||||
@zfs_dataset
|
||||
@zfs_dataset || "ZFS Dataset"
|
||||
end
|
||||
|
||||
def to_s
|
||||
|
|
|
@ -32,7 +32,7 @@ module Inspec::Resources
|
|||
end
|
||||
|
||||
def resource_id
|
||||
@zfs_pool
|
||||
@zfs_pool || "ZFS Pool"
|
||||
end
|
||||
|
||||
def to_s
|
||||
|
|
Loading…
Reference in a new issue