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
{{ message }}
This repository has been archived by the owner on Nov 23, 2021. It is now read-only.
When authentication is rejected, cancelAllAwaitingRequestsOnFailure is executed, which goes through the queue of responses and calls 'cancel' for all of them. Unfortunately cancel rejects a promise with no value provided. Interceptor plays with HTTP responses so it should always provide something compatible with this API. It is very likely to break promises chaining here, as failure callbacks might blindly try to read some basic information from response like data, status, url, headers etc. (in order to provide some feedback to the user).
I would propose to return original unauthorized response in case of canceling.
Cheers,
Bartek
The text was updated successfully, but these errors were encountered:
Hi,
When authentication is rejected, cancelAllAwaitingRequestsOnFailure is executed, which goes through the queue of responses and calls 'cancel' for all of them. Unfortunately cancel rejects a promise with no value provided. Interceptor plays with HTTP responses so it should always provide something compatible with this API. It is very likely to break promises chaining here, as failure callbacks might blindly try to read some basic information from response like data, status, url, headers etc. (in order to provide some feedback to the user).
I would propose to return original unauthorized response in case of canceling.
Cheers,
Bartek
The text was updated successfully, but these errors were encountered: