feat: add refresh token and global exception filter

This commit is contained in:
2026-05-09 09:00:25 +03:30
parent 06f659101d
commit 73f7af3146
32 changed files with 512 additions and 42 deletions
+6
View File
@@ -12,12 +12,16 @@ import { VerifyOTPProvider } from './providers/verify-otp.provider';
import { JwtStrategy } from './strategies/jwt.strategy';
import { APP_GUARD } from '@nestjs/core';
import { GlobalAuthGuard } from './guards/global-auth.guard';
import { RefreshTokensProvider } from './providers/refresh-tokens.provider';
import { RedisModule } from '@/common/modules/redis/redis.module';
import { AuthRedisProvider } from './providers/auth-redis.provider';
@Module({
imports: [
UsersModule,
OtpModule,
HashingModule,
RedisModule,
JwtModule.registerAsync({
inject: [ConfigService],
useFactory: (configService: ConfigService) => ({
@@ -37,6 +41,8 @@ import { GlobalAuthGuard } from './guards/global-auth.guard';
LoginProvider,
VerifyOTPProvider,
JwtStrategy,
RefreshTokensProvider,
AuthRedisProvider,
{
provide: APP_GUARD,
useClass: GlobalAuthGuard,