From 791c36f5df030ec01b9ec689a9b110b5d6ab03b0 Mon Sep 17 00:00:00 2001 From: Fabio Manganiello Date: Mon, 3 Dec 2018 23:04:23 +0100 Subject: [PATCH] More tolerance on json.loads() in case the parsed value from the request context is not a string --- platypush/message/request/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platypush/message/request/__init__.py b/platypush/message/request/__init__.py index f09f4adca..14db241d2 100644 --- a/platypush/message/request/__init__.py +++ b/platypush/message/request/__init__.py @@ -156,7 +156,7 @@ class Request(Message): value = '' try: return json.loads(parsed_value) - except ValueError as e: return parsed_value + except Exception as e: return parsed_value def _send_response(self, response):