diff --git a/web/login/login.py b/web/login/login.py index 34a9bfce1f59eba2fe3c55a829cef6a077c4c90e..ef54a182c28924aeff29031724cc53aa1a3d9261 100644 --- a/web/login/login.py +++ b/web/login/login.py @@ -262,7 +262,8 @@ def consent(): .filter(AppRole.user_id == user.uuid) .first() ) - if role_object is None or role_object.role_id is None: + # Role ID 3 is always "No access" due to migration b514cca2d47b + if role_object is None or role_object.role_id is None or role_object.role_id == 3: # If there is no role in app_roles or the role_id for an app is null user has no permissions current_app.logger.error(f"User has no access for: {app_obj.name}") return redirect(