summary refs log tree commit diff
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2019-02-22 14:47:48 +0000
committerErik Johnston <erik@matrix.org>2019-02-22 14:47:48 +0000
commit1d9df51ff1129f86157e54f0523cec0ddadcbd41 (patch)
tree3ca3ab8422b39fc439d064ac672b0cf7e1d81c75
parentAdd prometheus metrics for number of badge update pushes. (#4709) (diff)
downloadsynapse-1d9df51ff1129f86157e54f0523cec0ddadcbd41.tar.xz
Correctly handle null data in HttpPusher
-rw-r--r--synapse/push/httppusher.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/synapse/push/httppusher.py b/synapse/push/httppusher.py
index 899a5253d8..e65f8c63d3 100644
--- a/synapse/push/httppusher.py
+++ b/synapse/push/httppusher.py
@@ -97,6 +97,11 @@ class HttpPusher(object):
             pusherdict['pushkey'],
         )
 
+        if self.data is None:
+            raise PusherConfigException(
+                "data can not be null for HTTP pusher"
+            )
+
         if 'url' not in self.data:
             raise PusherConfigException(
                 "'url' required in data for HTTP pusher"