diff --git a/check_speedtest.py b/check_speedtest.py index ed1bb4b..8903113 100755 --- a/check_speedtest.py +++ b/check_speedtest.py @@ -39,9 +39,9 @@ def main(): elif speedtest_results['90th_percentile_download_speed']['value'] <= args.critical_down and exit_code < nagios.CRITICAL: exit_code = nagios.CRITICAL - if speedtest_results['latency_ms']['value'] <= args.warn_latency and exit_code < nagios.WARNING: + if speedtest_results['latency_ms']['value'] >= args.warn_latency and exit_code < nagios.WARNING: exit_code = nagios.WARNING - elif speedtest_results['latency_ms']['value'] <= args.warn_latency and exit_code < nagios.CRITICAL: + elif speedtest_results['latency_ms']['value'] >= args.warn_latency and exit_code < nagios.CRITICAL: exit_code = nagios.CRITICAL if exit_code == nagios.OK: