Skip to content

Commit

Permalink
Merge pull request #43090 from callstack-internal/fix/offline-interne…
Browse files Browse the repository at this point in the history
…t-reachability-check

fix: call net info refresh on each reachability check
  • Loading branch information
techievivek authored Jun 7, 2024
2 parents bb6e7eb + bd22f97 commit 461f3f5
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/libs/NetworkConnection.ts
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,10 @@ function subscribeToBackendAndInternetReachability(): () => void {
const intervalID = setInterval(() => {
// Offline status also implies backend unreachability
if (isOffline) {
// Periodically recheck the network connection
// More info: https://github.com/Expensify/App/issues/42988
recheckNetworkConnection();
Log.info(`[NetworkStatus] Rechecking the network connection with "isOffline" set to "true" to double-check internet reachability.`);
return;
}
// Using the API url ensures reachability is tested over internet
Expand Down

0 comments on commit 461f3f5

Please sign in to comment.