From ef63c3769e0ca026952ca1f52f7696cb8ae214c9 Mon Sep 17 00:00:00 2001 From: Fabio Manganiello Date: Sun, 31 Jan 2021 00:16:44 +0100 Subject: [PATCH] Cast request headers to dict before adding them to the event --- platypush/backend/http/app/routes/hook.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platypush/backend/http/app/routes/hook.py b/platypush/backend/http/app/routes/hook.py index dcc385cc..f9a41b40 100644 --- a/platypush/backend/http/app/routes/hook.py +++ b/platypush/backend/http/app/routes/hook.py @@ -26,7 +26,7 @@ def _hook(hook_name): 'method': request.method, 'args': dict(request.args or {}), 'data': request.data.decode(), - 'headers': request.headers, + 'headers': dict(request.headers or {}), } if event_args['data']: