mirror of
https://github.com/ZeppelinBot/Zeppelin.git
synced 2025-06-07 16:05:01 +00:00
refactor: move defaults to config schemas
This commit is contained in:
parent
09eb8e92f2
commit
83d35052c3
91 changed files with 450 additions and 888 deletions
|
@ -20,23 +20,11 @@ function getLogsPlugin(): Promise<any> {
|
|||
return import("../Logs/LogsPlugin.js") as Promise<any>;
|
||||
}
|
||||
|
||||
const defaultOptions = {
|
||||
config: {
|
||||
log_automatic_actions: true,
|
||||
case_log_channel: null,
|
||||
show_relative_times: true,
|
||||
relative_time_cutoff: "7d",
|
||||
case_colors: null,
|
||||
case_icons: null,
|
||||
},
|
||||
};
|
||||
|
||||
export const CasesPlugin = guildPlugin<CasesPluginType>()({
|
||||
name: "cases",
|
||||
|
||||
dependencies: async () => [TimeAndDatePlugin, InternalPosterPlugin, (await getLogsPlugin()).LogsPlugin],
|
||||
configParser: (input) => zCasesConfig.parse(input),
|
||||
defaultOptions,
|
||||
configSchema: zCasesConfig,
|
||||
|
||||
public(pluginData) {
|
||||
return {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue