feat: restrict access to inactive user profiles and update deactivation error messages
This commit is contained in:
@@ -151,7 +151,7 @@ export class AuthService {
|
||||
}
|
||||
|
||||
if (user.status !== UserStatus.ACTIVE) {
|
||||
throw new UnauthorizedException('Account is not active');
|
||||
throw new UnauthorizedException('Your account has been deactivated. Please contact support.');
|
||||
}
|
||||
|
||||
// Check if email is verified
|
||||
@@ -334,7 +334,7 @@ export class AuthService {
|
||||
}
|
||||
|
||||
if (user.status !== UserStatus.ACTIVE) {
|
||||
throw new UnauthorizedException('Account is not active');
|
||||
throw new UnauthorizedException('Your account has been deactivated. Please contact support.');
|
||||
}
|
||||
|
||||
// Generate tokens
|
||||
|
||||
Reference in New Issue
Block a user