https fetch throws exception on move from foreground to background and then back to foreground

Please provide the following:

  1. SDK Version: 35
  2. Platforms(Android/iOS/web/all): iOS

My app makes networking fetch calls that can take 5-10 seconds to return sometimes. If the user puts the app into the background and then later puts the app state to active, the fetch call throws an exception.

I don’t need to have the https fetch call actually process in the background, but is there a way for it to complete successfully once the app returns to the foreground (active) state?

Hey @todaq,

Are you using the BackgroundFetch module and this is occurring? Or are you just performing standard fetch calls?

Cheers,
Adam

standard fetch calls. I don’t need it to process in the background, I just need it to complete when the user brings the app back to the foreground. Do you have to use BackgroundFetch in this case?

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.