Skip to content

Commit 9d25066

Browse files
author
Henry Walshaw
committed
Fix the probe error check
Python3 division is always float. Much easier to check if the code is 400 or more.
1 parent 0561e1b commit 9d25066

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

GeoHealthCheck/probe.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,7 @@ def perform_request(self):
298298
if self.response:
299299
self.log('response: status=%d' % self.response.status_code)
300300

301-
if self.response.status_code / 100 in [4, 5]:
301+
if self.response.status_code >= 400:
302302
self.log('Error response: %s' % (str(self.response.text)))
303303

304304
def perform_get_request(self, url):

0 commit comments

Comments
 (0)