mirror of
https://github.com/inspec/inspec
synced 2024-11-23 21:23:29 +00:00
commit
8a9cd539fc
1 changed files with 7 additions and 5 deletions
|
@ -48,11 +48,13 @@ module Inspec
|
|||
|
||||
if @qualifier.length > 1
|
||||
last = @qualifier[-1]
|
||||
# preventing its('to_i') as the value returned is always 0
|
||||
if last.length == 1 && last[0] !~ /^to_.$/ && !last[0].include?('[')
|
||||
xres = last[0]
|
||||
else
|
||||
res += '.' + ruby_qualifier(last)
|
||||
unless last.is_a?(Array) && last[0].to_s.empty?
|
||||
if last.length == 1 && last[0] !~ /^to_.$/ && !last[0].include?('[')
|
||||
# this will go in its()
|
||||
xres = last[0]
|
||||
else
|
||||
res += '.' + ruby_qualifier(last)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue