Skip to content

Commit

Permalink
fix: 删除不可到达的代码、未使用的局部符号 retry
Browse files Browse the repository at this point in the history
  • Loading branch information
Ljzd-PRO committed Feb 9, 2025
1 parent a63a9af commit 720f25d
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
1 change: 0 additions & 1 deletion src/nonebot_plugin_mystool/command/login.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,6 @@ async def handle_first_receive(event: Union[GeneralMessageEvent]):
msg_img = QQGuildMessageSegment.file_image(image_bytes)
else:
await get_cookie.finish("⚠️发送二维码失败,无法登录")
return
try:
await get_cookie.send(msg_img)
except (ActionFailed, AuditException) as e:
Expand Down
3 changes: 1 addition & 2 deletions src/nonebot_plugin_mystool/utils/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -232,14 +232,13 @@ def generate_ds(data: Union[str, dict, list, None] = None, params: Union[str, di
return f"{t},{r},{c}"


async def get_validate(user: UserData, gt: str = None, challenge: str = None, retry: bool = True):
async def get_validate(user: UserData, gt: str = None, challenge: str = None):
"""
使用打码平台获取人机验证validate
:param user: 用户数据对象
:param gt: 验证码gt
:param challenge: challenge
:param retry: 是否允许重试
:return: 如果配置了平台URL,且 gt, challenge 不为空,返回 GeetestResult
"""
if not plugin_config.preference.global_geetest:
Expand Down

0 comments on commit 720f25d

Please sign in to comment.