Company logo
  • Jobs
  • Bootcamp
  • About Us
  • For professionals
    • Home
    • Jobs
    • Courses
    • Questions
    • Teachers
    • Bootcamp
  • For business
    • Home
    • Our process
    • Plans
    • Assessments
    • Payroll
    • Blog
    • Sales
    • Calculator

0

44
Views
Is there an alternative way to avoid that error?
module.exports = { 
    name: 'command',
    description: "Embeds!",
    execute(message, args, Discord) {
        const newEmbed = new Discord.MessageEmbed()
        .setColor('#304281')
        .setTitle('Rules')
        const newLocal = 'This is an embed for the server';
        setDescription(newLocal)
        .addFields(
            {name: 'Rule 1', value: 'Be good'},
            {name: 'Rule 2 ', value: 'Be polite'},
        )
        .setFooter('Make sure to check out that')

        message.channel.send(newEmbed);
    }
}

i need your help cause it prints me that error in terminal (i am new) (node:3712) DeprecationWarning: The message event is deprecated. Use messageCreate instead (Use node --trace-deprecation ... to show where the warning was created)

7 months ago · Juan Pablo Isaza
1 answers
Answer question

0

It is not an error just a warn. But you can just replace the event client.on('message', async () => ...) with client.on('messageCreate', async () => ...)

7 months ago · Juan Pablo Isaza Report
Answer question
Find remote jobs