interaction.channel.fetchPinned().then( messages => {
for(const [key, value] of messages)
{ //if I print messages here, I see a key=>value collection — but is there a better way to access the message by the ID I stored?
if(key == game.TURNMSG){
value.edit("Edited!");
//This doesn't edit the message...
break;
}
}
})
interaction.channel.fetchPinned().then( messages => {
for(const [key, value] of messages)
{ //if I print messages here, I see a key=>value collection — but is there a better way to access the message by the ID I stored?
if(key == game.TURNMSG){
value.edit("Edited!");
//This doesn't edit the message...
break;
}
}
})