3
0
Fork 0
mirror of https://github.com/ZeppelinBot/Zeppelin.git synced 2025-05-25 10:25:01 +00:00

Fix issues with circular dependencies between plugins

This commit is contained in:
Dragory 2021-08-18 19:33:22 +03:00
parent 171abe21f6
commit 44fbd020db
23 changed files with 36 additions and 29 deletions

View file

@ -108,6 +108,10 @@ import { logVoiceChannelLeave } from "./logFunctions/logVoiceChannelLeave";
import { logVoiceChannelMove } from "./logFunctions/logVoiceChannelMove";
import { logMemberTimedUnban } from "./logFunctions/logMemberTimedUnban";
import { logDmFailed } from "./logFunctions/logDmFailed";
import { CasesPlugin } from "../Cases/CasesPlugin";
// Workaround for circular dependency
const AnyTypedCasesPlugin = CasesPlugin as any;
const defaultOptions: PluginOptions<LogsPluginType> = {
config: {
@ -139,7 +143,7 @@ export const LogsPlugin = zeppelinGuildPlugin<LogsPluginType>()({
prettyName: "Logs",
},
dependencies: [TimeAndDatePlugin],
dependencies: () => [TimeAndDatePlugin, AnyTypedCasesPlugin],
configSchema: ConfigSchema,
defaultOptions,