Skip to content

Commit

Permalink
Merge pull request #5523 from marmelab/fix-setimmediate
Browse files Browse the repository at this point in the history
Fix setImmediate is not defined error
  • Loading branch information
djhi authored Nov 13, 2020
2 parents ccfbeb9 + 00ca8bc commit 98dffce
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/ra-core/src/dataProvider/useQueryWithStore.ts
Original file line number Diff line number Diff line change
Expand Up @@ -219,9 +219,9 @@ const useQueryWithStore = <State extends ReduxState = ReduxState>(
}
);
// cleanup the list on next tick
setImmediate(() => {
setTimeout(() => {
delete queriesThisTick[requestSignature];
});
}, 0);
}
(async () => {
const newState = await queriesThisTick[requestSignature];
Expand Down

0 comments on commit 98dffce

Please sign in to comment.