aboutsummaryrefslogtreecommitdiff
path: root/modules/rest_api.py
diff options
context:
space:
mode:
authorGravatar jesopo2018-10-06 09:24:43 +0100
committerGravatar jesopo2018-10-06 09:24:43 +0100
commit908edeb1e168afe19e17ac0b04c72d0579283863 (patch)
treee6b707ca2d39944b4b400d53b512557a1ae5736f /modules/rest_api.py
parentReturn 500 when an exception is thrown, never try to .encode None (diff)
signature
Typo in modules/github.py ('command' -> 'commit') and declare event_response
outside of try/except in modules/rest_api.py
Diffstat (limited to 'modules/rest_api.py')
-rw-r--r--modules/rest_api.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/modules/rest_api.py b/modules/rest_api.py
index d60a874b..bfee0d6f 100644
--- a/modules/rest_api.py
+++ b/modules/rest_api.py
@@ -27,6 +27,7 @@ class Handler(http.server.BaseHTTPRequestHandler):
code = 401
else:
if path.startswith("/api/"):
+ event_response = None
try:
event_response = _events.on("api").on(method).on(
endpoint).call_unsafe_for_result(