How can I set data to only update after a successful query is complete? - TanStack