Describe the bug
When using useInfiniteQuery with argument sent to a resolver function, enabled: false and keepPreviousData: true, data are deleted when one of arguments are changed.
To Reproduce
Steps to reproduce the behavior:
- Create useInfiniteQuery with some argument that is changing
- Set
enabled: false and keepPreviousData: true
- Fetch some data
- Change the argument
- Data are gone
Expected behavior
Data should remain
Desktop (please complete the following information):
- OS: MacOS
- Browser: firefox
- Version: 68
Additional context
react-query version: 2.14.1