Module: check_mk
Branch: master
Commit: b08a08b23235d9b42a26a733907f57d34a8d4975
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=b08a08b23235d9…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Tue Jun 5 13:22:26 2012 +0200
Better error message for missing view in mobile UI
---
web/htdocs/mobile.py | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/web/htdocs/mobile.py b/web/htdocs/mobile.py
index 2c361b2..f5240a1 100644
--- a/web/htdocs/mobile.py
+++ b/web/htdocs/mobile.py
@@ -209,6 +209,9 @@ def page_view():
return page_index()
view = html.available_views.get(view_name)
+ if not view:
+ raise MKGeneralException("No view defined with the name '%s'."
% view_name)
+
title = views.view_title(view)
mobile_html_head(title)