callback url

This commit is contained in:
Erik 2022-11-09 16:54:15 +02:00
parent 3563eeaf23
commit 68f0217be9
Signed by: Navy.gif
GPG Key ID: 811EC0CD80E7E5FB

View File

@ -31,7 +31,7 @@ class Server extends EventEmitter {
const { MARIA_HOST, MARIA_USER, MARIA_PORT, MARIA_PASS, MARIA_DB, const { MARIA_HOST, MARIA_USER, MARIA_PORT, MARIA_PASS, MARIA_DB,
MONGO_HOST, MONGO_USER, MONGO_PORT, MONGO_PASS, MONGO_DB, MONGO_HOST, MONGO_USER, MONGO_PORT, MONGO_PASS, MONGO_DB,
NODE_ENV, SECRET, DISCORD_SECRET, DISCORD_ID } = process.env; // Secret used for cookies, discord secret is for discord oauth NODE_ENV, SECRET, DISCORD_SECRET, DISCORD_ID } = process.env; // Secret used for cookies, discord secret is for discord oauth
const { discord, http: httpOpts, databases } = options; const { discord, http: httpOpts, databases, callbackURL } = options;
this._options = options; this._options = options;
this._shardId = parseInt(process.env.SHARD_ID); this._shardId = parseInt(process.env.SHARD_ID);
@ -59,7 +59,7 @@ class Server extends EventEmitter {
discordScope: discord.scope, discordScope: discord.scope,
discordSecret: DISCORD_SECRET, discordSecret: DISCORD_SECRET,
discordVersion: discord.version, discordVersion: discord.version,
callbackURL: `${this.baseURL}${discord.callbackURL}`, callbackURL: `${this.baseURL}${callbackURL}`,
cookie: { cookie: {
secure: true secure: true
} }