From cab5aab88515c15cae3d2ed8b268f7dd37d21f87 Mon Sep 17 00:00:00 2001 From: Aaron LI Date: Tue, 22 Nov 2016 13:06:47 +0800 Subject: webui: Add "/debug" handler when in debug mode. --- fg21sim/webui/handlers/base.py | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'fg21sim/webui/handlers') diff --git a/fg21sim/webui/handlers/base.py b/fg21sim/webui/handlers/base.py index 868ae48..0f93415 100644 --- a/fg21sim/webui/handlers/base.py +++ b/fg21sim/webui/handlers/base.py @@ -14,6 +14,13 @@ class BaseRequestHandler(tornado.web.RequestHandler): """ Base web request handler with user authentication support. """ + def get(self): + """ + Show the original HTTP request. DEBUG use. + + Credit: https://stackoverflow.com/a/3111656/4856091 + """ + self.write(repr(self.request)) def get_current_user(self): """ -- cgit v1.2.2