Skip to content

Commit 2403184

Browse files
Add redundant check for the code reading clarity
1 parent d3cc62c commit 2403184

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

conditional/blueprints/member_management.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,8 @@ def edit_uid(uid, user_name, post_data):
262262
db.session.flush()
263263
db.session.commit()
264264

265-
ldap_remove_member_from_group(uid, "onfloor")
265+
if ldap_is_member_of_group(uid, "onfloor"):
266+
ldap_remove_member_from_group(uid, "onfloor")
266267
ldap_set_housingpoints(uid, housing_points)
267268

268269
# Only update if there's a diff

0 commit comments

Comments
 (0)