mirror of
https://github.com/zulip/zulip.git
synced 2025-11-04 22:13:26 +00:00
settings: Migrate to stream_post_policy structure.
This commit includes a new `stream_post_policy` setting, by replacing the `is_announcement_only` field from the Stream model, which is done by mirroring the structure of the existing `create_stream_policy`. It includes the necessary schema and database migrations to migrate the is_announcement_only boolean field to stream_post_policy, a smallPositiveInteger field similar to many other settings. This change is done to allow organization administrators to restrict new members from creating and posting to a stream. However, this does not affect admins who are new members. With many tweaks by tabbott to documentation under /help, etc. Fixes #13616.
This commit is contained in:
@@ -328,7 +328,7 @@ def update_stream(client, stream_id):
|
||||
# Update the stream by a given ID
|
||||
request = {
|
||||
'stream_id': stream_id,
|
||||
'is_announcement_only': True,
|
||||
'stream_post_policy': 2,
|
||||
'is_private': True,
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user