添加一些对题解提交空格的情况判定

This commit is contained in:
2025-10-30 16:48:09 +08:00
parent fa208199ab
commit 490d807e7a
2 changed files with 28 additions and 10 deletions

View File

@ -305,7 +305,11 @@ def create_admin_commands():
if description is not None:
p.content = description
if flag is not None:
p.flag = flag
p.flag = flag.strip()
if flag.strip() != flag:
await target.send_message(
"⚠️ 注意:你输入的 Flag 含有开头或结尾的空格,已经帮你去除"
)
if image is not None and image.url is not None:
b = await download_image_bytes(image.url)
p.add_image(b.unwrap())