fix(invalidate): keep invalidate default behaviour [BE-11064] (#12080)

pull/12145/head
Ali 3 months ago committed by GitHub
parent 59b3375b59
commit 10767a06df
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -37,9 +37,7 @@ export function withInvalidate(
return { return {
onSuccess() { onSuccess() {
const promise = Promise.all( const promise = Promise.all(
queryKeysToInvalidate.map((keys) => queryKeysToInvalidate.map((keys) => queryClient.invalidateQueries(keys))
queryClient.invalidateQueries(keys, { refetchType: 'none' })
)
); );
return skipRefresh return skipRefresh
? undefined // don't wait for queries to refresh before setting state to success ? undefined // don't wait for queries to refresh before setting state to success

Loading…
Cancel
Save