From 67b7905e66a4b7f07dd06388a336ba0a2959656e Mon Sep 17 00:00:00 2001 From: austinkelsay Date: Fri, 15 Nov 2024 14:31:53 -0600 Subject: [PATCH] Fix config --- next.config.js | 32 +++++++++++++++++--------------- 1 file changed, 17 insertions(+), 15 deletions(-) diff --git a/next.config.js b/next.config.js index 6d7290b..a62a94b 100644 --- a/next.config.js +++ b/next.config.js @@ -26,6 +26,23 @@ module.exports = removeImports({ }, async headers() { return [ + { + source: "/.well-known/:slug*", + headers: [ + { + key: "Access-Control-Allow-Origin", + value: "*" + }, + { + key: "Access-Control-Allow-Methods", + value: "GET, POST, OPTIONS" + }, + { + key: "Access-Control-Allow-Headers", + value: "Content-Type, Authorization" + } + ] + }, { source: "/api/:slug*", headers: [ @@ -62,21 +79,6 @@ module.exports = removeImports({ value: "max-age=31536000; includeSubDomains; preload" }, ], - source: "/api/.well-known/:slug*", - headers: [ - { - key: "Access-Control-Allow-Origin", - value: "*" - }, - { - key: "Access-Control-Allow-Methods", - value: "GET, POST, PUT, DELETE, OPTIONS", - }, - { - key: 'Cache-Control', - value: 'no-cache, max-age=0, must-revalidate' - } - ], }, ]; },