diff --git a/api/src/modules/auth/strategies/jwt.strategy.ts b/api/src/modules/auth/strategies/jwt.strategy.ts index 16a1786c..66f2dbca 100644 --- a/api/src/modules/auth/strategies/jwt.strategy.ts +++ b/api/src/modules/auth/strategies/jwt.strategy.ts @@ -23,7 +23,7 @@ export class JwtStrategy extends PassportStrategy(Strategy) { async validate(payload: JwtPayload) { const { id } = payload; const user = await this.userService.findOneBy(id); - if (!user) { + if (!user || !user.isActive) { throw new UnauthorizedException(); } return user;