Formatting everything with black
This commit is contained in:
1 parent
42a11c0dc6
commit
a3539beda9
20 files changed
+173
-18
No files matched your search
@@ -1,4 +1,5 @@
|
||||
"""Token issuance / rotation shared by the JSON API and the HTMX UI."""
|
||||
|
||||
import jwt
|
||||
from sqlalchemy.ext.asyncio import AsyncSession
|
||||
|
||||
@@ -30,7 +31,9 @@ class RefreshError(Exception):
|
||||
pass
|
||||
|
||||
|
||||
async def rotate_refresh_token(db: AsyncSession, raw_refresh: str) -> tuple[str, str, User]:
|
||||
async def rotate_refresh_token(
|
||||
db: AsyncSession, raw_refresh: str
|
||||
) -> tuple[str, str, User]:
|
||||
"""Validate a refresh token, revoke it, and issue a fresh pair.
|
||||
|
||||
Raises ``RefreshError`` if the token is invalid, expired, or already revoked.
|
||||
|
||||
Reference in new issue
Block a user