Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
events: Send enter_sends if update_display_settings in fetch_event_types.
Sahil Batra79b0ff5b23eb
diff --git a/templates/zerver/api/changelog.md b/templates/zerver/api/changelog.mdindex 775f599a7f0..6e92ea9659c 100644--- a/templates/zerver/api/changelog.md+++ b/templates/zerver/api/changelog.md@@ -11,6 +11,12 @@ below features are supported.## Changes in Zulip 5.0+**Feature level 84**++* [`POST /register`](/api/register-queue): The `enter_sends` setting+ is now sent when `update_display_setting` is present in+ `fetch_event_types` instead of `realm_user`.+**Feature level 83*** * [`POST /register`](/api/register-queue): The `cross_realm_bots`diff --git a/version.py b/version.pyindex 473d5a5e4f3..46baeeb2657 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 = 83+API_FEATURE_LEVEL = 84# 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/events.py b/zerver/lib/events.pyindex 9ecb4630b0f..c7c73b83640 100644--- a/zerver/lib/events.py+++ b/zerver/lib/events.py@@ -384,7 +384,6 @@ def fetch_initial_state_data(state["is_guest"] = settings_user.is_gueststate["is_billing_admin"] = settings_user.is_billing_adminstate["user_id"] = settings_user.id- state["enter_sends"] = settings_user.enter_sendsstate["email"] = settings_user.emailstate["delivery_email"] = settings_user.delivery_emailstate["full_name"] = settings_user.full_name@@ -502,10 +501,6 @@ def fetch_initial_state_data(if want("update_display_settings"):for prop in UserProfile.property_types:- if prop == "enter_sends":- # This will be removed when we make the API change to- # move this to the update_display_settings event type.- continuestate[prop] = getattr(settings_user, prop)state["emojiset_choices"] = UserProfile.emojiset_choices()state["timezone"] = settings_user.timezonediff --git a/zerver/openapi/zulip.yaml b/zerver/openapi/zulip.yamlindex 8eadd1eae86..d676b3d71fc 100644--- a/zerver/openapi/zulip.yaml+++ b/zerver/openapi/zulip.yaml@@ -9579,10 +9579,14 @@ paths:enter_sends:type: booleandescription: |- Present if `realm_user` is present in `fetch_event_types`.+ Present if `update_display_settings` is present in `fetch_event_types`.Whether the user setting for [sending on pressing Enter](/help/enable-enter-to-send)in the compose box is enabled.++ **Changes**: Prior to Zulip 5.0 (feature level 84) this field was present+ in response if 'realm_user' was present in `fetch_event_types`, not+ `update_display_settings`.user_id:type: integerdescription: |