1
0
Fork 0
mirror of https://github.com/plankanban/planka.git synced 2025-07-19 13:19:44 +02:00

feat: correct bool according to the name (inversion of enable and disable)

This commit is contained in:
Aurélien TRONCY 2024-08-29 00:26:49 +02:00
parent 9a5049472f
commit 82b03e5542
2 changed files with 3 additions and 3 deletions

View file

@ -63,7 +63,7 @@ module.exports = {
sails.log.warn(
`Invalid email or username: "${inputs.emailOrUsername}"! (IP: ${remoteAddress})`,
);
if (sails.config.custom.enableVerboseOnLogin) {
if (!sails.config.custom.enableVerboseOnLogin) {
throw Errors.INVALID_CREDENTIALS;
}
throw Errors.INVALID_EMAIL_OR_USERNAME;
@ -75,7 +75,7 @@ module.exports = {
if (!bcrypt.compareSync(inputs.password, user.password)) {
sails.log.warn(`Invalid password! (IP: ${remoteAddress})`);
if (sails.config.custom.enableVerboseOnLogin) {
if (!sails.config.custom.enableVerboseOnLogin) {
throw Errors.INVALID_CREDENTIALS;
}
throw Errors.INVALID_PASSWORD;

View file

@ -36,7 +36,7 @@ module.exports.custom = {
allowAllToCreateProjects: process.env.ALLOW_ALL_TO_CREATE_PROJECTS === 'true',
enableVerboseOnLogin: process.env.ENABLE_VERBOSE_ON_LOGIN ? process.env.ENABLE_VERBOSE_ON_LOGIN === 'true' : true,
enableVerboseOnLogin: process.env.ENABLE_VERBOSE_ON_LOGIN ? process.env.ENABLE_VERBOSE_ON_LOGIN === 'true' : false,
oidcIssuer: process.env.OIDC_ISSUER,
oidcClientId: process.env.OIDC_CLIENT_ID,