Reaction Collector not working properly Discord Bot

Ok so basically I am making a reaction collector but for some reason when I use the reaction collector on an embed it wont work.

 const sendembed = new Discord.MessageEmbed()
        .setTitle(`test`)
        .setAuthor(message.author.username)
        .setFooter(`RO`)

      const msg = message.channel.send(sendembed).then(async msg => {
        await msg.react('πŸ‘');
        await msg.react('πŸ‘Ž');
        const filter = (reaction,user) => ['thumbsup','thumbsdown'].includes(reaction.emoji.name) && user.id === message.author.id
        const collectore = msg.createReactionCollector(filter)
        
        collectore.on('collect', async r => {
          switch(r.emoji.name) {
            case 'thumbsup':
              message.channel.send('Hello')
              collector.stop();
              break;
            case 'thumbsdown':
              message.channel.send('Bye')
              collector.stop();
              break;
          }
        })
      })

If you don’t get a response here I will suggest you join the Discord.JS discord server and you should have and answer within a few minutes.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.