parent
350c8ea5ff
commit
8fa25eb201
@ -0,0 +1,12 @@ |
||||
const Discord = require('discord.js'); |
||||
|
||||
const AniData = require('../../models/anime'); |
||||
|
||||
module.exports = async client => { |
||||
client.misc.cache.anime = new Discord.Collection(); |
||||
|
||||
for await (const ani of AniData.find()) { |
||||
client.misc.cache.anime.set(ani.japname, ani.id); |
||||
client.misc.cache.anime.set(ani.name, ani.id); |
||||
} |
||||
} |
@ -0,0 +1,11 @@ |
||||
const Discord = require('discord.js'); |
||||
|
||||
const CharData = require('../../models/char'); |
||||
|
||||
module.exports = async client => { |
||||
client.misc.cache.chars = new Discord.Collection(); |
||||
|
||||
for await (const char of CharData.find()) { |
||||
client.misc.cache.chars.set(char.name, char.id); |
||||
} |
||||
} |
Loading…
Reference in new issue