what if api secret auth actually… did the right thing? just kidding… unless

This commit is contained in:
Laura Klünder 2023-11-15 14:04:07 +01:00
parent f9e5af937e
commit da4631b715

View file

@ -38,8 +38,7 @@ class BearerAuth(HttpBearer):
).select_related("user").get()
except UserPermissions.DoesNotExist:
raise APITokenInvalid
session = self.SessionStore(token.removeprefix("secret:"))
return session.user
return user_perms.user
# todo: implement token (app) auth
raise APITokenInvalid