/home/container/src/commands/music/Play.js:21 try } ^SyntaxError: Unexpected token '}'

I'm having difficulty pinpointing which bracket is causing a syntax error in my code. I've tried various fixes, but I can't seem to resolve the issue. Could you offer some assistance? Your help would be greatly appreciated.
4 Replies
d.js toolkit
d.js toolkit10mo ago
- What's your exact discord.js npm list discord.js and node node -v version? - Not a discord.js issue? Check out #other-js-ts. - Consider reading #how-to-get-help to improve your question! - Explain what exactly your issue is. - Post the full error stack trace, not just the top part! - Show your code! - Issue solved? Press the button!
Rutr Runs
Rutr Runs10mo ago
Point to note: There is more than one bracket missing..
} catch (e) {
message.channel.send({ content: `${client.emoji.cross} | Found some error please try other source` });
// Log the error
console.error(`Error: ${e.message}`);
}
}
module.exports = Play;
} catch (e) {
message.channel.send({ content: `${client.emoji.cross} | Found some error please try other source` });
// Log the error
console.error(`Error: ${e.message}`);
}
}
module.exports = Play;
I also know that the try {} doen't have a bracket. ping me if you answer.
Pulse
Pulse10mo ago
try } think not sure if thats what you meant by
I also know that the try {} doen't have a bracket.
but yeah that is a problem
Rutr Runs
Rutr Runs10mo ago
I’ve fixed that