Module: check_mk
Branch: master
Commit: af54e0156de4130ce45d509488526384b2fcf580
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=af54e0156de413…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Fri Apr 5 12:51:27 2013 +0200
snapins: Reverted yesterdays encoding "fix"; switched output to manual json
formating
---
web/htdocs/sidebar.py | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/web/htdocs/sidebar.py b/web/htdocs/sidebar.py
index 85932ea..ea46437 100644
--- a/web/htdocs/sidebar.py
+++ b/web/htdocs/sidebar.py
@@ -309,13 +309,14 @@ def ajax_snapin():
snapin["render"]()
except Exception, e:
snapin_exception(e)
- snapin_code.append(html.drain().encode('utf-8'))
+ snapin_code.append(html.drain())
html.unplug()
- html.write(repr(snapin_code))
- except:
+ html.write('[%s]' % ','.join([ "'%s'" % s for s
in snapin_code]))
+ except Exception, e:
html.flush()
html.unplug()
+ html.log('Exception during snapin refresh: %s' % e)
raise
def move_snapin():