From 64ec4139403c6054b09e11bf2a2de98543c237f5 Mon Sep 17 00:00:00 2001 From: Pragati Agrawal Date: Sat, 22 Feb 2020 00:43:14 +0530 Subject: [PATCH] settings user groups: Fix organization admin can not create user groups. The bug was in complex `if` condition, which should mean that users should be allowed to create a User group only when they are either admin or user group creation policy is set to everyone. Fixes: #13909. --- static/templates/user_groups_admin.hbs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/static/templates/user_groups_admin.hbs b/static/templates/user_groups_admin.hbs index f18e41cfea..592a57a8fd 100644 --- a/static/templates/user_groups_admin.hbs +++ b/static/templates/user_groups_admin.hbs @@ -11,7 +11,7 @@

{{#tr this}}User groups allow you to mention multiple users at once. When you mention a user group, everyone in the group is notified as if they were individually mentioned.{{/tr}}

- {{#unless (and (not (eq realm_user_group_edit_policy USER_GROUP_EDIT_POLICY_MEMBERS) (not is_admin)))}} + {{#if (or is_admin (eq realm_user_group_edit_policy USER_GROUP_EDIT_POLICY_MEMBERS))}}
@@ -31,7 +31,7 @@
- {{/unless}} + {{/if}} {{/unless}}