From ba0c5296bfa6f5cc884d18ef9045edd52942da6b Mon Sep 17 00:00:00 2001 From: rijkvanzanten Date: Tue, 10 Aug 2021 11:13:43 -0400 Subject: [PATCH] Fix graphql GET request cache query extraction Fixes #7298 --- api/src/utils/get-cache-key.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/src/utils/get-cache-key.ts b/api/src/utils/get-cache-key.ts index 30236ee829af9..99f83e54f3634 100644 --- a/api/src/utils/get-cache-key.ts +++ b/api/src/utils/get-cache-key.ts @@ -8,7 +8,7 @@ export function getCacheKey(req: Request): string { const info = { user: req.accountability?.user || null, path, - query: path?.includes('/graphql') ? req.params.query : req.sanitizedQuery, + query: path?.includes('/graphql') ? req.query.query : req.sanitizedQuery, }; const key = hash(info);