mirror of
https://github.com/puppetlabs/vmfloaty.git
synced 2026-01-26 05:28:40 -05:00
Merge branch 'master' into bump_version_to_0.9.0
This commit is contained in:
commit
dac2c2bae6
3 changed files with 48 additions and 4 deletions
|
|
@ -57,11 +57,19 @@ class ABS
|
|||
requests = JSON.parse(res.body)
|
||||
|
||||
ret_val = []
|
||||
requests.each do |req|
|
||||
req_hash = JSON.parse(req)
|
||||
next unless user == req_hash['request']['job']['user']
|
||||
|
||||
ret_val.push(req_hash)
|
||||
requests.each do |req|
|
||||
next if req == 'null'
|
||||
|
||||
req_hash = JSON.parse(req)
|
||||
|
||||
begin
|
||||
next unless user == req_hash['request']['job']['user']
|
||||
|
||||
ret_val.push(req_hash)
|
||||
rescue NoMethodError
|
||||
puts "Warning: couldn't parse line returned from abs/status/queue: ".yellow
|
||||
end
|
||||
end
|
||||
|
||||
ret_val
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue