Skip to content

Commit

Permalink
adjustment for compiler compat
Browse files Browse the repository at this point in the history
  • Loading branch information
phryneas committed Jul 12, 2024
1 parent 037ea25 commit 0eaf524
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions src/react/hooks/useQuery.ts
Original file line number Diff line number Diff line change
Expand Up @@ -370,16 +370,12 @@ function useObservableSubscriptionResult<
skipStandbyResult
: void 0;

const previousData = resultData.previousData;
const currentResultOverride = React.useMemo(
() =>
resultOverride &&
toQueryResult(
resultOverride,
resultData.previousData,
observable,
client
),
[client, observable, resultOverride, resultData.previousData]
toQueryResult(resultOverride, previousData, observable, client),
[client, observable, resultOverride, previousData]
);

return useSyncExternalStore(
Expand Down

0 comments on commit 0eaf524

Please sign in to comment.