From c967de6761a1b0aca1f9428db00eb6b8d499294d Mon Sep 17 00:00:00 2001 From: Mark Erikson Date: Sun, 29 Sep 2024 15:14:11 +0300 Subject: [PATCH] Hack around TS issues --- packages/toolkit/src/query/react/buildHooks.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/packages/toolkit/src/query/react/buildHooks.ts b/packages/toolkit/src/query/react/buildHooks.ts index 403a4e57bc..e3d9bfef72 100644 --- a/packages/toolkit/src/query/react/buildHooks.ts +++ b/packages/toolkit/src/query/react/buildHooks.ts @@ -1562,7 +1562,9 @@ export function buildHooks({ skipPollingIfUnfocused = false, } = {}, ) => { - const { initiate } = api.endpoints[name] as ApiEndpointInfiniteQuery< + const { initiate } = api.endpoints[ + name + ] as unknown as ApiEndpointInfiniteQuery< InfiniteQueryDefinition, Definitions > @@ -1725,7 +1727,7 @@ export function buildHooks({ ) => { const { select, initiate } = api.endpoints[ name - ] as ApiEndpointInfiniteQuery< + ] as unknown as ApiEndpointInfiniteQuery< InfiniteQueryDefinition, Definitions >