From d38e555293f4f73263b591d5054302c7cbd124c7 Mon Sep 17 00:00:00 2001 From: Maksim Eltyshev Date: Tue, 9 Aug 2022 19:09:07 +0200 Subject: [PATCH] fix: Provide default value for token expiration --- server/config/custom.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/config/custom.js b/server/config/custom.js index 9b3d86ef..8d8043c2 100644 --- a/server/config/custom.js +++ b/server/config/custom.js @@ -20,7 +20,7 @@ module.exports.custom = { baseUrl: process.env.BASE_URL, - tokenExpiresIn: process.env.TOKEN_EXPIRES_IN, + tokenExpiresIn: parseInt(process.env.TOKEN_EXPIRES_IN, 10) || 365, userAvatarsPath: path.join(sails.config.paths.public, 'user-avatars'), userAvatarsUrl: `${process.env.BASE_URL}/user-avatars`,