push_notifs: Log the number of devices notification was sent to.

This commit is contained in:
Mateusz Mandera
2021-09-28 14:17:16 +02:00
committed by Tim Abbott
parent ed023db0f4
commit 0af7c84c99
4 changed files with 84 additions and 10 deletions

View File

@@ -107,8 +107,10 @@ def send_to_push_bouncer(
return orjson.loads(res.content)
def send_json_to_push_bouncer(method: str, endpoint: str, post_data: Mapping[str, object]) -> None:
send_to_push_bouncer(
def send_json_to_push_bouncer(
method: str, endpoint: str, post_data: Mapping[str, object]
) -> Dict[str, object]:
return send_to_push_bouncer(
method,
endpoint,
orjson.dumps(post_data),