Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
api: Include `stream_id` field for all edits to stream messages.
Lauryn Menard3b72da8a7ce9
diff --git a/templates/zerver/api/changelog.md b/templates/zerver/api/changelog.mdindex d42a13d8c6d..f82904a6424 100644--- a/templates/zerver/api/changelog.md+++ b/templates/zerver/api/changelog.md@@ -20,6 +20,11 @@ format used by the Zulip server that they are interacting with.## Changes in Zulip 5.0+**Feature level 112**++* [`GET /events`](/api/get-events): Updated `update_message` event type+ to include `stream_id` field for all edits to stream messages.+**Feature level 111*** [`POST /subscriptions/properties`](/api/update-subscription-settings):diff --git a/version.py b/version.pyindex e6ccd364259..ece79ef0831 100644--- a/version.py+++ b/version.py@@ -33,7 +33,7 @@ DESKTOP_WARNING_VERSION = "5.4.3"# Changes should be accompanied by documentation explaining what the# new level means in templates/zerver/api/changelog.md, as well as# "**Changes**" entries in the endpoint's documentation in `zulip.yaml`.-API_FEATURE_LEVEL = 111+API_FEATURE_LEVEL = 112# Bump the minor PROVISION_VERSION to indicate that folks should provision# only when going from an old version of the code to a newer version. Bumpdiff --git a/zerver/lib/actions.py b/zerver/lib/actions.pyindex 9c15c34a249..23be7898ce5 100644--- a/zerver/lib/actions.py+++ b/zerver/lib/actions.py@@ -6287,6 +6287,7 @@ def do_update_message(stream_id = target_message.recipient.type_idstream_being_edited = get_stream_by_id_in_realm(stream_id, realm)event["stream_name"] = stream_being_edited.name+ event["stream_id"] = stream_being_edited.idums = 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_idif new_stream is not None:assert content is Nonediff --git a/zerver/openapi/zulip.yaml b/zerver/openapi/zulip.yamlindex bc06c4760a8..e4e1b27288c 100644--- a/zerver/openapi/zulip.yaml+++ b/zerver/openapi/zulip.yaml@@ -2030,6 +2030,11 @@ paths:The pre-edit stream for all of the messages with IDs in`message_ids`.++ **Changes**: As of Zulip 5.0 (feature level 112), this field+ is present for all edits to a stream message. Previously, it+ was not present when only the content of the stream message was+ edited.new_stream_id:type: integerdescription: |