Module: check_mk
Branch: master
Commit: 191b66fa87472688820ccdcbfc055e37eae1813a
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=191b66fa874726…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Fri Oct 27 09:51:34 2017 +0200
5423 FIX Fixed exception on "Catalog of check plugins page"
The exception was caused by man pages having an empty "catalog:" header
declaration.
Change-Id: I1e1dab5fc64c66030abd0c15a2bfd04aa01c32d4
---
.werks/5423 | 10 ++++++++++
lib/man_pages.py | 2 +-
2 files changed, 11 insertions(+), 1 deletion(-)
diff --git a/.werks/5423 b/.werks/5423
new file mode 100644
index 0000000..6fca388
--- /dev/null
+++ b/.werks/5423
@@ -0,0 +1,10 @@
+Title: Fixed exception on "Catalog of check plugins page"
+Level: 1
+Component: wato
+Compatible: compat
+Edition: cre
+Version: 1.5.0i1
+Date: 1509090617
+Class: fix
+
+The exception was caused by man pages having an empty "catalog:" header
declaration.
diff --git a/lib/man_pages.py b/lib/man_pages.py
index 8da4488..99779dc 100644
--- a/lib/man_pages.py
+++ b/lib/man_pages.py
@@ -291,7 +291,7 @@ def load_man_page_catalog():
raise
parsed = _create_fallback_man_page(name, path, e)
- if "catalog" in parsed:
+ if parsed.get("catalog"):
cat = parsed["catalog"]
else:
cat = [ "unsorted" ]