Count as error only for 4xx and 5xx http status codes

This commit is contained in:
Dmytro Khmelenko 2021-10-08 16:20:22 +02:00 committed by GitHub
parent c0c202c170
commit eb86183362
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -57,7 +57,7 @@ def validate_links(links):
})
code = int(resp[0]['status'])
# Checking status code errors
if (code >= 300):
if (code >= 400):
hasError = True
print(f"ERR:CLT:{code} : {link}")
except TimeoutError: