mirror of
https://github.com/zulip/zulip.git
synced 2025-11-09 16:37:23 +00:00
api: Include stream_id field for all edits to stream messages.
Updates the `update_message` event type to always include a `stream_id` field when the message being edited is a stream message. This change aligns with the current definition of the `\get-events` endpoint in the OpenAPI documentation.
This commit is contained in:
committed by
Tim Abbott
parent
1dc36c3f16
commit
3b72da8a7c
@@ -6287,6 +6287,7 @@ def do_update_message(
|
||||
stream_id = target_message.recipient.type_id
|
||||
stream_being_edited = get_stream_by_id_in_realm(stream_id, realm)
|
||||
event["stream_name"] = stream_being_edited.name
|
||||
event["stream_id"] = stream_being_edited.id
|
||||
|
||||
ums = UserMessage.objects.filter(message=target_message.id)
|
||||
|
||||
@@ -6380,7 +6381,6 @@ def do_update_message(
|
||||
if topic_name is not None or new_stream is not None:
|
||||
orig_topic_name = target_message.topic_name()
|
||||
event["propagate_mode"] = propagate_mode
|
||||
event["stream_id"] = target_message.recipient.type_id
|
||||
|
||||
if new_stream is not None:
|
||||
assert content is None
|
||||
|
||||
Reference in New Issue
Block a user