(client: any, msg: Api.Message, parts: string[])
| 124 | const operation = parts[3]?.toLowerCase(); |
| 125 | |
| 126 | if (!action) { |
| 127 | await this.sendError(msg, "请指定清理类型: pm (私聊) 或 member (群组)"); |
| 128 | return; |
| 129 | } |
| 130 | |
| 131 | switch (action) { |
| 132 | case "pm": |
| 133 | await this.cleanDeletedPM(client, msg, operation === "rm"); |
| 134 | break; |
| 135 | case "member": |
| 136 | await this.cleanDeletedMember(client, msg, operation === "rm"); |
| 137 | break; |
| 138 | default: |
| 139 | await this.sendError(msg, `未知类型: ${htmlEscape(action)}`); |
| 140 | break; |
| 141 | } |
| 142 | } |
| 143 | |
| 144 | // 处理拉黑/解封清理 |
| 145 | private async handleBlockedClean(client: any, msg: Api.Message, parts: string[]): Promise<void> { |
| 146 | const action = parts[2]?.toLowerCase(); |
| 147 | const mode = parts[3]?.toLowerCase(); |
| 148 | |
| 149 | if (!action) { |
no test coverage detected