MCPcopy Create free account
hub / github.com/TeleBoxOrg/TeleBox_Plugins / removeExitMessage

Method removeExitMessage

autodelcmd/autodelcmd.ts:526–539  ·  view source on GitHub ↗
(msg: Api.Message)

Source from the content-addressed store, hash-verified

524 const chatId = this.getChatId(msg);
525 if (chatId) {
526 const exitMsgs = await this.loadExitMessages();
527 const filteredMsgs = exitMsgs.filter(
528 exitMsg => !(exitMsg.cid === chatId && exitMsg.mid === msg.id)
529 );
530 await this.saveExitMessages(filteredMsgs);
531 }
532 } catch (error) {
533 console.error(`[autodelcmd] 清理删除任务失败:`, error);
534 }
535 }
536
537 // 配置管理方法
538 public async addCustomRule(rule: CommandRule): Promise<{ success: boolean; error?: string; merged?: boolean }> {
539 if (!this.config.customRules) {
540 this.config.customRules = [];
541 }
542

Callers 1

delayDeleteMethod · 0.95

Calls 4

getChatIdMethod · 0.95
loadExitMessagesMethod · 0.95
saveExitMessagesMethod · 0.95
errorMethod · 0.80

Tested by

no test coverage detected