My code is below. Users are supposed to easily react to a message and it opens a new ticket. Someone told me to filter out bots or something, however, the bot opens up its own ticket, deletes the reaction and I am only left with the gray question mark one. It doesn’t even work when I react to it. I’m pretty new to coding. The bot just opens up its own.
const { MessageEmbed } = require("discord.js")
module.exports = {
name: 'ticketembed',
async execute(message, client) {
const ticketEmbed = new MessageEmbed()
.setTitle(":tickets: | Support Tickets")
.setDescription(`Found a bug, or error? Have a question, or another concern? Would you like to partner with us? Click one of the buttons corresponding to what we listed here!nn???? - Report a bugn❓ - General Supportn❔ - Partnerships`)
.setColor("#2F3136")
await message.delete();
const ticketEmbedMsg = await message.channel.send({ embeds: [ticketEmbed] });
await ticketEmbedMsg.react("????");
await ticketEmbedMsg.react("❓");
await ticketEmbedMsg.react("❔");
}
}
New contributor
fred erbxx is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.