Skip to content

Commit

Permalink
#93 ensure to wait for the current scan report - if report exist, giv…
Browse files Browse the repository at this point in the history
…e the last available one even if a scan has been asked and is in progress
  • Loading branch information
jeromeleonard committed Oct 26, 2017
1 parent df281f0 commit b3df3c0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion analyzers/VirusTotal/virustotal.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ def wait_file_report(self, id):
def wait_url_report(self, id):
results = self.check_response(self.vt.get_url_report(id))
code = results.get('response_code', None)
if code == 1:
if code == 1 and (results.get('scan_id') == id):
self.report(results)
else:
time.sleep(self.polling_interval)
Expand Down

1 comment on commit b3df3c0

@BrevilleBro
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice, thanks @jeromeleonard .

Please sign in to comment.