diff --git a/geruecht/controller/accesTokenController.py b/geruecht/controller/accesTokenController.py index b23e2d1..dd7a4ae 100644 --- a/geruecht/controller/accesTokenController.py +++ b/geruecht/controller/accesTokenController.py @@ -33,9 +33,11 @@ class AccesTokenController(metaclass=Singleton): def checkBar(self, user): if (userController.checkBarUser(user)): - user.group.append(BAR) - elif BAR in user.group: - user.group.remove(BAR) + if BAR not in user.group: + user.group.append(BAR) + else: + while BAR in user.group: + user.group.remove(BAR) def validateAccessToken(self, token, group): """ Verify Accestoken