Closed DeekoDan closed 2 years ago
Can you verify by console logging process.env.token
it will show your token?
Also make sure you are using nodejs version 14
ok let me try
Also make sure you are using nodejs version 14
i am using nodejs version
process.env.token
Also what do you mean by this
This is what I have in the env files token="token here" owner_id=769446561016184852 log_channel_id=836768745644490765
i am using nodejs version
Discordjs uses a syntax (??)
that is only supported in nodejs 14 and above
This is what I have in the env files token="token here" owner_id=769446561016184852 log_channel_id=836768745644490765
There is no need for double quotation, That could be why it's causing an error
So i did the exact same thing and its still giving me it
Full Error
SyntaxError: Unexpected token =
at Module._compile (internal/modules/cjs/loader.js:723:23)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
at Function.Module._load (internal/modules/cjs/loader.js:585:3)
at Module.require (internal/modules/cjs/loader.js:692:17)
at require (internal/modules/cjs/helpers.js:25:18)
at Object.node main.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the DiscordStream@1.0.0 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in: npm ERR! /home/sircrosar/.npm/_logs/2021-10-10T05_13_26_394Z-debug.log
Sorry, I helped you as much as I could
ok..
I encountered the same error when nodejs version was below 14 Please upgrade the nodejs
SyntaxError: Unexpected token = at Module._compile (internal/modules/cjs/loader.js:723:23) at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10) at Module.load (internal/modules/cjs/loader.js:653:32) at tryModuleLoad (internal/modules/cjs/loader.js:593:12) at Function.Module._load (internal/modules/cjs/loader.js:585:3) at Module.require (internal/modules/cjs/loader.js:692:17) at require (internal/modules/cjs/helpers.js:25:18) at Object. (/home/sircrosar/Desktop/Discord-Screenshare-master/main.js:2:20)
at Module._compile (internal/modules/cjs/loader.js:778:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
sircrosar@ubuntu:~/Desktop/Discord-Screenshare-master$