From 71d8e95315e945aa512bf0dbbcceb2699d33195f Mon Sep 17 00:00:00 2001 From: adueck Date: Mon, 30 Jan 2023 00:10:25 +0500 Subject: [PATCH] another cors config --- account/src/index.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/account/src/index.ts b/account/src/index.ts index 0538eca..eb5e15c 100644 --- a/account/src/index.ts +++ b/account/src/index.ts @@ -14,10 +14,10 @@ const sameOriginCorsOpts = { origin: inProd ? /\.lingdocs\.com$/ : "*", credentials: true, }; -const openCorsOpts = { - origin: "*", - credentials: false, -}; +// const openCorsOpts = { +// origin: "*", +// credentials: false, +// }; const app = express(); // MIDDLEWARE AND SETUP 🔧 // @@ -41,7 +41,7 @@ app.use("/feedback", cors(sameOriginCorsOpts), feedbackRouter); // TODO: check - does this work with the cors ? app.use("/payment", cors(sameOriginCorsOpts), paymentRouter); // Dictionary API -app.use("/dictionary", cors(openCorsOpts), dictionaryRouter); +app.use("/dictionary", cors(), dictionaryRouter); // START 💨 // app.listen(4000, () => console.log("Server Has Started on 4000"));