Fix the login password verification (#568)

* Fix the login password verification

* Update the check criteria
This commit is contained in:
Wu Clan
2025-04-07 11:04:39 +08:00
committed by GitHub
parent b93ff19ebe
commit 644f7a0413
2 changed files with 12 additions and 5 deletions
+2 -1
View File
@@ -61,7 +61,8 @@ async def get_tokens(
extra_info = await redis_client.get(f'{settings.TOKEN_EXTRA_INFO_REDIS_PREFIX}:{session_uuid}')
if extra_info:
extra_info = json.loads(extra_info)
if extra_info.get('login_type') != 'swagger':
# 排除 swagger 登录生成的 token
if extra_info.get('swagger') is None:
if username is not None:
if username == extra_info.get('username'):
append_token_detail()