Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Add cache for NetService state
With previous implementation, NetService would do reachability tests too often and sometimes multiple times in parallel (as we can call `isOnline` from multiple parallel `client.query()` calls) This is problematic as it can unnecessary slow down the app processes This commit caches the isOnline result and register to the `NetInfo` event listener so stay up-to-date, so we can drastically reduce reachability tests on Cozy's servers
- Loading branch information