From 049f206c8a8536b2b3ff7f2eca0320abf1c9e4ff Mon Sep 17 00:00:00 2001 From: Vinayak Sarawagi Date: Thu, 15 Aug 2024 11:39:38 +0530 Subject: [PATCH] fix cors error --- lib/rest/restServer.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/rest/restServer.ts b/lib/rest/restServer.ts index 958085b..8b2bd93 100644 --- a/lib/rest/restServer.ts +++ b/lib/rest/restServer.ts @@ -24,7 +24,7 @@ export class RestServer { if (config.get('app.cors') || options?.cors) { const corsRule = options?.cors ?? config.get('app.cors'); - app.enable(corsRule); + app.enableCors(corsRule); } /**