Module: check_mk
Branch: master
Commit: c606da0425db2f0fdf0bd9aa7ddefd31602a18b3
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=c606da0425db2f…
Author: Simon Betz <si(a)mathias-kettner.de>
Date: Wed Jun 28 16:00:06 2017 +0200
4879 FIX akcp_sensor_humidity, akcp_exp_humidity: Fixed wrong order of level evaluation
Change-Id: Ie471b11051f7820eaffe3941bb0a46647c805b6a
---
.werks/4879 | 11 +++++++++++
checks/akcp_sensor.include | 4 ++--
2 files changed, 13 insertions(+), 2 deletions(-)
diff --git a/.werks/4879 b/.werks/4879
new file mode 100644
index 0000000..dac8c97
--- /dev/null
+++ b/.werks/4879
@@ -0,0 +1,11 @@
+Title: akcp_sensor_humidity, akcp_exp_humidity: Fixed wrong order of level evaluation
+Level: 1
+Component: checks
+Class: fix
+Compatible: compat
+Edition: cre
+State: unknown
+Version: 1.5.0i1
+Date: 1498658323
+
+
diff --git a/checks/akcp_sensor.include b/checks/akcp_sensor.include
index 427d00f..3be3cc1 100644
--- a/checks/akcp_sensor.include
+++ b/checks/akcp_sensor.include
@@ -106,12 +106,12 @@ def check_akcp_humidity(item, params, info):
if humidity <= crit_lower:
return 2, infotext + belowtext, perfdata
+ elif humidity >= crit:
+ return 2, infotext + abovetext, perfdata
elif humidity <= warn_lower:
return 1, infotext + belowtext, perfdata
elif humidity >= warn:
return 1, infotext + abovetext, perfdata
- elif humidity >= crit:
- return 2, infotext + abovetext, perfdata
else:
return 0, infotext, perfdata