bugfix for #1098 (assigning a group to a user, the group appears incrementally many times the more you assign it)