changes to make the default redirect endpoint in chase of page authentication error
Release Inventarsystem / release-docker (push) Successful in 2m14s

This commit is contained in:
2026-08-14 20:20:59 +02:00
parent 61d726f8f4
commit 21ad639081
+1 -2
View File
@@ -825,9 +825,8 @@ def _action_access_allowed(permissions, action_key):
def _permission_denied_fallback_endpoint(permissions, current_endpoint=None): def _permission_denied_fallback_endpoint(permissions, current_endpoint=None):
username = session.get('username') username = session.get('username')
is_admin_user = bool(username and us.check_admin(username))
for candidate in ('my_borrowed_items', 'tutorial_page', 'notifications_view', 'impressum', 'home_admin'): for candidate in ('home_admin', 'my_borrowed_items', 'tutorial_page', 'notifications_view', 'impressum'):
if current_endpoint and candidate == current_endpoint: if current_endpoint and candidate == current_endpoint:
continue continue
if _page_access_allowed(permissions, candidate): if _page_access_allowed(permissions, candidate):