mirror of
https://github.com/inspec/inspec
synced 2024-11-10 15:14:23 +00:00
inspec-compliance: style
This commit is contained in:
parent
e0bd2bb595
commit
7b740a2f9d
1 changed files with 4 additions and 6 deletions
|
@ -85,14 +85,12 @@ module Compliance
|
|||
|
||||
if !data.nil?
|
||||
profiles = JSON.parse(data)
|
||||
val = []
|
||||
# iterate over profiles
|
||||
profiles.each_key do |org|
|
||||
profiles[org].each_key do |name|
|
||||
val.push({ org: org, name: name })
|
||||
profiles.map do |owner, ps|
|
||||
ps.keys.map do |name|
|
||||
{ org: owner, name: name }
|
||||
end
|
||||
end
|
||||
val
|
||||
end.flatten
|
||||
else
|
||||
[]
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue