bot
commited on
Commit
·
695ef74
1
Parent(s):
1fbfa8d
fix
Browse files
main.py
CHANGED
@@ -304,8 +304,6 @@ async def handle_file_operation(update: Update, context: CallbackContext):
|
|
304 |
# 获取操作类型和文件 ID
|
305 |
action, file_id = query.data.split(":")
|
306 |
|
307 |
-
print(f"Performing action: {action} for file_id: {file_id}")
|
308 |
-
|
309 |
# 需要确认的操作
|
310 |
if action in ["delete_file"]:
|
311 |
# 生成确认消息
|
@@ -537,6 +535,10 @@ async def init_client():
|
|
537 |
|
538 |
########## 文件操作 ###############
|
539 |
|
|
|
|
|
|
|
|
|
540 |
TG_BOT_APPLICATION.add_handler(
|
541 |
CallbackQueryHandler(handle_file_operation, pattern="^delete_file:")
|
542 |
)
|
|
|
304 |
# 获取操作类型和文件 ID
|
305 |
action, file_id = query.data.split(":")
|
306 |
|
|
|
|
|
307 |
# 需要确认的操作
|
308 |
if action in ["delete_file"]:
|
309 |
# 生成确认消息
|
|
|
535 |
|
536 |
########## 文件操作 ###############
|
537 |
|
538 |
+
TG_BOT_APPLICATION.add_handler(
|
539 |
+
CallbackQueryHandler(tg_show_files, pattern="^list_file:")
|
540 |
+
)
|
541 |
+
|
542 |
TG_BOT_APPLICATION.add_handler(
|
543 |
CallbackQueryHandler(handle_file_operation, pattern="^delete_file:")
|
544 |
)
|