From c9ce5d6e3a16cdbcef9bbc3050acbede6c7666df Mon Sep 17 00:00:00 2001 From: Emilio Date: Fri, 12 Sep 2025 12:51:32 -0600 Subject: [PATCH] se agregaron cambios --- src/main.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/main.ts b/src/main.ts index 1968aa9..52a9e55 100644 --- a/src/main.ts +++ b/src/main.ts @@ -13,7 +13,11 @@ import { SwaggerModule, DocumentBuilder } from '@nestjs/swagger'; async function bootstrap() { const app = await NestFactory.create(AppModule); - app.enableCors({ exposedHeaders: ['Content-Disposition'] }); + app.enableCors({ + origin: [process.env.FRONTEND_URL], // solo frontend permitido + methods: 'GET,HEAD,PUT,PATCH,POST,DELETE', + credentials: true, + }); app.useGlobalPipes( new ValidationPipe({