diff --git a/api_docs/changelog.md b/api_docs/changelog.md index 3d706554d2..0c9c7caf91 100644 --- a/api_docs/changelog.md +++ b/api_docs/changelog.md @@ -24,6 +24,10 @@ format used by the Zulip server that they are interacting with. * Mobile push notification payloads for APNs no longer contain the `server` and `realm_id` fields, which were unused. +* Mobile push notification payloads for FCM to remove push + notifications no longer contain the legacy pre-2019 + `zulip_message_id` field; all functional clients support the newer + `zulip_message_ids`. **Feature level 412** diff --git a/zerver/lib/push_notifications.py b/zerver/lib/push_notifications.py index 92ea7be508..dea1474c16 100644 --- a/zerver/lib/push_notifications.py +++ b/zerver/lib/push_notifications.py @@ -1203,9 +1203,6 @@ def get_remove_payload_gcm( gcm_payload.update( event="remove", zulip_message_ids=",".join(str(id) for id in message_ids), - # Older clients (all clients older than 2019-02-13) look only at - # `zulip_message_id` and ignore `zulip_message_ids`. Do our best. - zulip_message_id=message_ids[0], ) gcm_options = {"priority": "normal"} return gcm_payload, gcm_options diff --git a/zerver/tests/test_handle_push_notification.py b/zerver/tests/test_handle_push_notification.py index 8463f732fa..598bf3d8e9 100644 --- a/zerver/tests/test_handle_push_notification.py +++ b/zerver/tests/test_handle_push_notification.py @@ -655,7 +655,6 @@ class HandlePushNotificationTest(PushNotificationTestCase): "user_id": self.user_profile.id, "event": "remove", "zulip_message_ids": str(message.id), - "zulip_message_id": message.id, }, {"priority": "normal"}, list( @@ -724,7 +723,6 @@ class HandlePushNotificationTest(PushNotificationTestCase): "user_id": self.user_profile.id, "event": "remove", "zulip_message_ids": str(message.id), - "zulip_message_id": message.id, }, {"priority": "normal"}, )