Ask coding questions

← Back to all posts
SyntaxError: Invalid left-hand side in assignment?
zxcv51523 (0)

Im making a discord.js bot with a friend, but i'm getting this error
/home/runner/TnT/config.js:2
"default_prefix" = "tnt!",
^^^^^^^^^^^^^^^^

SyntaxError: Invalid left-hand side in assignment

I just dont understand?
The code i have in index.js:
const { default_prefix, ownerID, token } = require('/home/runner/TnT/config')

Any way to fix this?

Comments
hotnewtop
zxcv51523 (0)

quick upd: Fixed but it says the token is invalid.