feat(lst): added in delay global function
This commit is contained in:
3
server/globalUtils/delay.ts
Normal file
3
server/globalUtils/delay.ts
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
export const delay = (ms: number) => {
|
||||||
|
return new Promise((resolve) => setTimeout(resolve, ms));
|
||||||
|
};
|
||||||
@@ -43,7 +43,7 @@ app.use(
|
|||||||
origin: "*", // Allow all origins
|
origin: "*", // Allow all origins
|
||||||
allowHeaders: ["Content-Type", "Authorization", "X-Requested-With"],
|
allowHeaders: ["Content-Type", "Authorization", "X-Requested-With"],
|
||||||
allowMethods: ["GET", "POST", "PUT", "DELETE", "OPTIONS", "PATCH"],
|
allowMethods: ["GET", "POST", "PUT", "DELETE", "OPTIONS", "PATCH"],
|
||||||
exposeHeaders: ["Content-Length", "X-Kuma-Revision"],
|
//exposeHeaders: ["Content-Length", "X-Kuma-Revision"],
|
||||||
credentials: true, // Allow credentials if needed
|
credentials: true, // Allow credentials if needed
|
||||||
maxAge: 600,
|
maxAge: 600,
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user