push_notifications: Include stream_id in the notification data.

Closes #18067.
Previous only the stream name was sent, which is an unstable stream
identifier.
This commit is contained in:
Mateusz Mandera
2022-01-29 22:59:06 +01:00
committed by Tim Abbott
parent 487e7ccd11
commit c0f7158378
4 changed files with 15 additions and 1 deletions

View File

@@ -714,6 +714,7 @@ def get_message_payload(
if message.recipient.type == Recipient.STREAM:
data["recipient_type"] = "stream"
data["stream"] = get_display_recipient(message.recipient)
data["stream_id"] = message.recipient.type_id
data["topic"] = message.topic_name()
elif message.recipient.type == Recipient.HUDDLE:
data["recipient_type"] = "private"