📈 Open source, privacy-first web analytics — a cookie-less Google Analytics alternative with built-in error tracking and performance monitoring. Self-host it or use our cloud. Get started for free!
TypeScript chartsclickhousedockergdprgoogle-analyticsmetricsmonitoringmysqlnestjsprivacyredisself-hostedselfhostedstatisticstailwindcssweb-analyticswebanalyticswebsite
fix: broken API key route
Blue Mouseb1e90689cbb1
diff --git a/web/app/routes/api.api-keys.ts b/web/app/routes/api.api-keys.tsindex 59dbe5464..a3c3bfb48 100644--- a/web/app/routes/api.api-keys.ts+++ b/web/app/routes/api.api-keys.ts@@ -32,9 +32,12 @@ export async function loader({ request }: LoaderFunctionArgs) {export async function action({ request }: ActionFunctionArgs) {redirectIfNotAuthenticated(request)const origin = request.headers.get('origin')+ const fetchSite = request.headers.get('sec-fetch-site')if (- request.headers.get('sec-fetch-site') === 'cross-site' ||- (origin && origin !== new URL(request.url).origin) ||+ fetchSite === 'cross-site' ||+ (fetchSite !== 'same-origin' &&+ origin &&+ origin !== new URL(request.url).origin) ||!request.headers.get('content-type')?.startsWith('application/json')) {return data(