From 0457a23868534eb5c396c0d562c3fa5ad3671552 Mon Sep 17 00:00:00 2001 From: xtaodada Date: Thu, 28 Mar 2024 22:05:57 +0800 Subject: [PATCH] :art: wish log do not auto-remove when send image --- plugins/starrail/wish_log.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/plugins/starrail/wish_log.py b/plugins/starrail/wish_log.py index 61ecfa1..ca0efa5 100644 --- a/plugins/starrail/wish_log.py +++ b/plugins/starrail/wish_log.py @@ -350,15 +350,15 @@ class WishLogPlugin(Plugin.Conversation): png_data = await self.rander_wish_log_analysis(user_id, uid, pool_type) if isinstance(png_data, str): reply = await message.reply_text(png_data) + if filters.ChatType.GROUPS.filter(message): + self.add_delete_message_job(reply) + self.add_delete_message_job(message) else: await message.reply_chat_action(ChatAction.UPLOAD_PHOTO) if png_data.file_type == FileType.DOCUMENT: - reply = await png_data.reply_document(message, filename="抽卡统计.png") + await png_data.reply_document(message, filename="抽卡统计.png") else: - reply = await png_data.reply_photo(message) - if filters.ChatType.GROUPS.filter(message): - self.add_delete_message_job(reply) - self.add_delete_message_job(message) + await png_data.reply_photo(message) @handler.command(command="warp_log", block=False) @handler.message(filters=filters.Regex("^跃迁记录?(光锥|角色|常驻|新手)$"), block=False)