Skip to content
This repository has been archived by the owner on Feb 16, 2021. It is now read-only.

Commit

Permalink
Merge pull request #150 from mozilla/fix_status_for_complete_scans
Browse files Browse the repository at this point in the history
Re-add status key to scan results
  • Loading branch information
Jonathan Claudius committed Sep 17, 2018
2 parents 1262ee7 + ceb131c commit 48e4685
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/ssh_scan_api/api.rb
Expand Up @@ -143,7 +143,9 @@ class Api < Sinatra::Base
when "RUNNNING"
return {"status" => "RUNNNING"}.to_json
when "COMPLETED"
return scan.raw_scan
parsed_scan = JSON.parse(scan.raw_scan)
parsed_scan["status"] = "COMPLETED"
return parsed_scan.to_json
else
return {"status" => "UNKNOWN"}.to_json
end
Expand Down

0 comments on commit 48e4685

Please sign in to comment.