mirror of
https://github.com/ZeppelinBot/Zeppelin.git
synced 2025-05-10 20:35:02 +00:00
perf: use a memory cache for AutoReactions
This commit is contained in:
parent
31f18ba27f
commit
d09d6b776a
5 changed files with 24 additions and 3 deletions
|
@ -33,7 +33,11 @@ export const AutoReactionsPlugin = zeppelinGuildPlugin<AutoReactionsPluginType>(
|
|||
`),
|
||||
},
|
||||
|
||||
dependencies: () => [LogsPlugin],
|
||||
// prettier-ignore
|
||||
dependencies: () => [
|
||||
LogsPlugin,
|
||||
],
|
||||
|
||||
configSchema: ConfigSchema,
|
||||
defaultOptions,
|
||||
|
||||
|
@ -51,5 +55,6 @@ export const AutoReactionsPlugin = zeppelinGuildPlugin<AutoReactionsPluginType>(
|
|||
beforeLoad(pluginData) {
|
||||
pluginData.state.savedMessages = GuildSavedMessages.getGuildInstance(pluginData.guild.id);
|
||||
pluginData.state.autoReactions = GuildAutoReactions.getGuildInstance(pluginData.guild.id);
|
||||
pluginData.state.cache = new Map();
|
||||
},
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue