SimonLeclere / discord-easy-dashboard

💻 Simple module to facilitate the creation of dashboard using discord.js and express
https://www.npmjs.com/package/discord-easy-dashboard
71 stars 11 forks source link

Secret as String #36

Open ghost opened 1 year ago

ghost commented 1 year ago

Hey, can I put the secret as a string or does it need to be in a .env?

SimonLeclere commented 1 year ago

You can put it as a string but I recommend that you store it in an .env to avoid leaking and make the configuration of your project simpler.

ghost commented 1 year ago

Thank you

ghost commented 1 year ago

I added this secret: process.env.DISCORD_SECRET but it still shows this in console "Without the client.secret parameter, some features of discord-easy-dashboard will be disabled, like Discord authentification or guild settings..." nor is /auth/login accessible. Returns a 404 page Yes, I did define the secret.

SimonLeclere commented 1 year ago

Do you have dotenv installed ?

ghost commented 1 year ago

Yes, I do

SimonLeclere commented 1 year ago

Maybe try logging process.env.DISCORD_SECRET in the console idk

SimonLeclere commented 1 year ago

Do you have one of theses lines somewhere in your code ?

import 'dotenv/config' require('dotenv').config()