fix: compatibility with old session IDs

This commit is contained in:
Éloi Rivard 2024-04-09 15:45:47 +02:00
parent 4037c296cf
commit 7ad592c4de
No known key found for this signature in database
GPG key ID: 7EDA204EA57DD184
2 changed files with 2 additions and 1 deletions

View file

@ -5,6 +5,7 @@ Added
Fixed
^^^^^
- HTMX and JAVASCRIPT configuration settings.
- Compatibility with old sessions IDs.
[0.0.49] - 2024-04-08
---------------------

View file

@ -20,7 +20,7 @@ def current_user():
return g.user
for user_id in session.get("user_id", [])[::-1]:
user = models.User.get(id=user_id)
user = models.User.get(user_id)
if user and (
not current_app.backend.has_account_lockability() or not user.locked
):