mirror of
				https://github.com/zulip/zulip.git
				synced 2025-11-03 21:43:21 +00:00 
			
		
		
		
	types: Add default_group_name field to GroupPermissionSetting type.
This commit adds default_group_name field to GroupPermissionSetting type which will be used to store the name of the default group for that setting which would in most cases be one of the role-based system groups. This will be helpful when we would have multiple settings and we would need to set the defaults while creating realm and streams.
This commit is contained in:
		@@ -591,8 +591,13 @@ def add_subscriptions_backend(
 | 
			
		||||
            allow_nobody_group=False,
 | 
			
		||||
        )
 | 
			
		||||
    else:
 | 
			
		||||
        can_remove_subscribers_group_default = Stream.stream_permission_group_settings[
 | 
			
		||||
            "can_remove_subscribers_group"
 | 
			
		||||
        ].default_group_name
 | 
			
		||||
        can_remove_subscribers_group = UserGroup.objects.get(
 | 
			
		||||
            name="@role:administrators", realm=user_profile.realm, is_system_group=True
 | 
			
		||||
            name=can_remove_subscribers_group_default,
 | 
			
		||||
            realm=user_profile.realm,
 | 
			
		||||
            is_system_group=True,
 | 
			
		||||
        )
 | 
			
		||||
 | 
			
		||||
    for stream_dict in streams_raw:
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user