Sync-in · Sovereign platform for file storage, sharing, synchronization, and collaboration.
TypeScript cloud-alternativecollaborationcollaborative-editingdropboxfile-serverfile-sharingfile-storagefile-syncfull-text-searchhomelabnextcloudon-premiseopen-sourceprivacy-firstprivate-cloudrealtimesecureself-hostedstorage-serverwebdav
fix(backend:auth): prevent lock emails for already disabled accounts
johavencee35be799d5
diff --git a/backend/src/applications/users/services/users-manager.service.ts b/backend/src/applications/users/services/users-manager.service.tsindex f70cb19d..3b6a2860 100755--- a/backend/src/applications/users/services/users-manager.service.ts+++ b/backend/src/applications/users/services/users-manager.service.ts@@ -161,7 +161,9 @@ export class UsersManager {if (!user.isActive || user.passwordAttempts >= USER_MAX_PASSWORD_ATTEMPTS) {this.updateAccesses(user, ip, false).catch((e: Error) => this.logger.error({ tag: this.validateUserAccess.name, msg: `${e}` }))this.logger.error({ tag: this.validateUserAccess.name, msg: `user account *${user.login}* is locked` })- this.notifyAccountLocked(user, ip)+ if (user.isActive) {+ this.notifyAccountLocked(user, ip)+ }throw new HttpException('Account locked', HttpStatus.FORBIDDEN)}}