Answers for "discord.js get the message before"

1

discord.js get the message before

message.channel.fetchMessages({limit: 2})
.then(messageMappings => {
let messages = Array.from(messageMappings.values());
let previousMessage = messages[1];
// do something with previous message
})
.catch(error => console.log(error))
Posted by: Guest on July-13-2020

Code answers related to "discord.js get the message before"

Code answers related to "Javascript"

Browse Popular Code Answers by Language