fixed bug with job init

This commit is contained in:
Wyatt Johnson
2017-07-27 15:14:11 +10:00
parent 1a1d28c915
commit a54a240ae6
8 changed files with 48 additions and 63 deletions
+2 -2
View File
@@ -34,7 +34,7 @@ if (JWT_SECRETS) {
return new jwt.AsymmetricSecret(secret, JWT_ALG);
}));
debug(`loaded ${JWT_SECRET.length} secrets`);
debug(`loaded ${JWT_SECRET.length} ${JWT_ALG.startsWith('HS') ? 'shared' : 'asymmetric'} secrets`);
} else if (JWT_SECRET) {
if (JWT_ALG.startsWith('HS')) {
module.exports.jwt = new jwt.SharedSecret({
@@ -44,5 +44,5 @@ if (JWT_SECRETS) {
module.exports.jwt = new jwt.AsymmetricSecret(JSON.parse(JWT_SECRET), JWT_ALG);
}
debug('loaded 1 secret');
debug(`loaded a ${JWT_ALG.startsWith('HS') ? 'shared' : 'asymmetric'} secret`);
}