From 81d8cd8a07d948e6228c5e260ff4426ce61c7d4c Mon Sep 17 00:00:00 2001 From: marcos-silva-rodrigues Date: Thu, 15 May 2025 11:00:07 -0300 Subject: [PATCH] FIX: default value to header origin --- docsfera.json | 8 -------- src/modules/auth/auth.controller.ts | 2 +- 2 files changed, 1 insertion(+), 9 deletions(-) diff --git a/docsfera.json b/docsfera.json index b8d9671..b6e8be8 100644 --- a/docsfera.json +++ b/docsfera.json @@ -20,14 +20,6 @@ ], "type": "string" } - }, - { - "name": "origin", - "required": true, - "in": "header", - "schema": { - "type": "string" - } } ], "requestBody": { diff --git a/src/modules/auth/auth.controller.ts b/src/modules/auth/auth.controller.ts index 226036a..7f2f8f0 100644 --- a/src/modules/auth/auth.controller.ts +++ b/src/modules/auth/auth.controller.ts @@ -86,7 +86,7 @@ export class AuthController { async signIn( @Body() { username, password, totp }: AuthSignInReq, @Language() language: LanguageEnum, - @Headers('origin') origin: string, + @Headers('origin') origin = '', ): Promise { this.logger.info('/auth - SignIn'); const frontHost = origin.replace(/^https?:\/\//, '');