'DiscordJS V12 client.guilds.cache.get(...).emojis.forEach is not a function
let static = [], animated = [];
client.guilds.cache.get('911491194654175242').emojis.forEach(emoji => emoji.animated ? animated.push([emoji.id, emoji.name]) : static.push([emoji.id, emoji.name]));
console.log('Static Emojis\n');
static.forEach(emoji => console.log('<:' + emoji[1] + ':' + emoji[0] + '>'));
console.log('\nAnimated Emojis\n');
animated.forEach(emoji => console.log('<a:' + emoji[1] + ':' + emoji[0] + '>'));
This is my code for my ready event, I am trying to log all the emojis in my guild to the console to make my life easier but returns an error client.guilds.cache.get(...).emojis.forEach is not a function
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
