send_message: Add an optional parameter in the success response.

Add an optional `automatic_new_visibility_policy` enum field
in the success response to indicate the new visibility policy
value due to the `automatically_follow_topics_policy` and
`automatically_unmute_topics_in_muted_streams_policy` user settings
during the send message action.

Only present if there is a change in the visibility policy.
This commit is contained in:
Prakhar Pratyush
2023-10-09 16:41:32 +05:30
committed by Tim Abbott
parent 0c649ff2aa
commit 17a0304309
11 changed files with 136 additions and 29 deletions

View File

@@ -118,7 +118,9 @@ From image editing program:
for message in staged_messages
]
message_ids = do_send_messages(messages)
message_ids = [
sent_message_result.message_id for sent_message_result in do_send_messages(messages)
]
preview_message = Message.objects.get(
id__in=message_ids, content__icontains="image previews"