(
client: TelegramClient,
chatId: any,
userId: number,
participant?: any
)
| 848 | } |
| 849 | } catch (error) { |
| 850 | console.error(`[GroupManager] 获取群组失败: ${error}`); |
| 851 | } |
| 852 | |
| 853 | return groups; |
| 854 | } |
| 855 | |
| 856 | static async clearCache(): Promise<void> { |
| 857 | await this.cache.clear(); |
| 858 | } |
| 859 | } |
| 860 | |
| 861 | // ==================== 封禁操作管理器 ==================== |
| 862 | type BatchGroupFailure = { |
| 863 | group: ManagedGroup; |
| 864 | reason: string; |
| 865 | }; |
| 866 | |
| 867 | type ChatKind = "channel" | "chat"; |
| 868 | |
| 869 | type BatchBanResult = { |
| 870 | success: number; |
| 871 | failed: number; |
| 872 | failedGroups: string[]; |
| 873 | failureDetails: BatchGroupFailure[]; |
| 874 | unresolved: boolean; |
no test coverage detected