module.exports = { name: 'interactionCreate', async execute(interaction) { if(interaction.isButton()){ console.log(interaction); interaction.reply({ content: `${interaction.user.tag} clicked me`, ephemeral : true }); } if (!interaction.isCommand()) return; const command = interaction.client.commands.get(interaction.commandName); if (!command) return; try { await command.execute(interaction); } catch (error) { console.error(error); await interaction.reply({ content: 'There was an error while executing this command!', ephemeral: true }); } console.log(`${interaction.user.tag} in #${interaction.channel.name} triggered an interaction.`); }, };