From e2208315d45a6789c99d3f4afe696a79f557e3fb Mon Sep 17 00:00:00 2001 From: Nikita Karamov Date: Wed, 30 Aug 2023 13:31:31 +0200 Subject: [PATCH] Improve caching --- src/pages/api/detect/[domain].ts | 2 +- src/pages/api/instances.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pages/api/detect/[domain].ts b/src/pages/api/detect/[domain].ts index 413e4c5..1e8cb9c 100644 --- a/src/pages/api/detect/[domain].ts +++ b/src/pages/api/detect/[domain].ts @@ -116,7 +116,7 @@ export const get: APIRoute = async ({ params }) => { { status: 200, headers: { - "Cache-Control": "s-maxage=86400, max-age=86400, public", + "Cache-Control": "public, s-maxage=86400, max-age=604800", "Content-Type": "application/json", }, }, diff --git a/src/pages/api/instances.ts b/src/pages/api/instances.ts index 3fd07c4..ecc3b01 100644 --- a/src/pages/api/instances.ts +++ b/src/pages/api/instances.ts @@ -57,7 +57,7 @@ export const get: APIRoute = async () => { ), { headers: { - "Cache-Control": "s-maxage=86400, max-age=86400, public", + "Cache-Control": "public, s-maxage=86400, max-age=604800", "Content-Type": "application/json", }, },