From 5b95593d9c1e4ed7c3992313993c4d29901cd91e Mon Sep 17 00:00:00 2001 From: "Navy.gif" Date: Thu, 10 Nov 2022 20:47:08 +0200 Subject: [PATCH] things --- files/index.html | 4 ++-- src/server/Server.js | 2 +- src/server/structures/User.js | 2 ++ 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/files/index.html b/files/index.html index aaa43d7..176ed8d 100644 --- a/files/index.html +++ b/files/index.html @@ -17,7 +17,7 @@

Log in

-
+

@@ -26,7 +26,7 @@

Register

-
+

diff --git a/src/server/Server.js b/src/server/Server.js index 9009d6c..c9ef3d2 100644 --- a/src/server/Server.js +++ b/src/server/Server.js @@ -167,7 +167,7 @@ class Server extends EventEmitter { this.logger.info(`${profile.username} (${profile.id}) is logging in.`); const user = await this.userDatabase.userFromDiscord(profile); callback(null, user); - }), { successRedirect: '/api/login/discord/finalise' }); + }), { successRedirect: '/home' }); this.authenticator.addStrategy('local', new LocalStrategy(async (username, password, callback) => { const user = await this.userDatabase.findUser(username); diff --git a/src/server/structures/User.js b/src/server/structures/User.js index e01dd2a..5986f6c 100644 --- a/src/server/structures/User.js +++ b/src/server/structures/User.js @@ -30,6 +30,8 @@ class User { /** @private */ this._passwordHash = data.password || null; + this.cachedTimestamp = Date.now(); + } get id () {