You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
When using retries, when the fetch is in the delay stage, i.e. delayed between retries, calling the abort function from the useFetch() hook has no effect.
⚠️ Make a Codesandbox ⚠️
Please do this to easily reproduce the bug.
To Reproduce
Steps to reproduce the behavior:
attach the abort() function to a button
make a fetch call that will cause a retry, with a reasonable delay for testing, say 5 secs.
after the first request has fullfilled and the fetch hook will delay for 5 secs before making the next request
during the delay, before the next request happens, click the button to call abort()
nothing happens, and the next request will eventually happen after the defined 5 secs.
click the button whilst the request is still in flight
it is finally aborted
Expected behavior
If delays are possible, it shouldn't matter when the abort is clicked, the subsequent requests should be aborted, not just an in flight request.
The text was updated successfully, but these errors were encountered:
Describe the bug
When using retries, when the fetch is in the delay stage, i.e. delayed between retries, calling the
abort
function from theuseFetch()
hook has no effect.Please do this to easily reproduce the bug.
To Reproduce
Steps to reproduce the behavior:
abort()
function to a buttonabort()
Expected behavior
If delays are possible, it shouldn't matter when the abort is clicked, the subsequent requests should be aborted, not just an in flight request.
The text was updated successfully, but these errors were encountered: