fix: reduce noise in logs

pull/406/head
Raphaël Vinot 2022-05-05 01:22:59 +02:00
parent adaddc591c
commit fa3d84da81
1 changed files with 5 additions and 1 deletions

View File

@ -109,7 +109,11 @@ class Phishtank():
urls = self.client.get_urls_by_ip(ip)
if not urls:
ip_storage_dir.rmdir()
try:
ip_storage_dir.rmdir()
except OSError:
# no need to print an exception.
pass
return
to_dump = {'ip': ip, 'urls': urls}
with pt_file.open('w') as _f: