refactor(project): make pyright & ruff happy

This commit is contained in:
MingxuanGame
2025-08-22 08:21:52 +00:00
parent 3b1d7a2234
commit 598fcc8b38
157 changed files with 2382 additions and 4590 deletions

View File

@@ -56,11 +56,9 @@ async def connect(
return
try:
async for session in factory():
if (
user := await get_current_user(
session, SecurityScopes(scopes=["*"]), token_pw=token
)
) is None or str(user.id) != user_id:
if (user := await get_current_user(session, SecurityScopes(scopes=["*"]), token_pw=token)) is None or str(
user.id
) != user_id:
await websocket.close(code=1008)
return
except HTTPException: