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
constnaviMonitor=(response)=>{try{if(response.status===401){console.warn('Unhandled session expiration')signOut()}}catch(e){console.log(e)// the error you throwed at transformation}}api.addMonitor(naviMonitor)
I have addResponseTransform for transform data form respond and handle error message then throw to catch later
And I have addMonitor for handle status like 401 for auto-logout
but don't work when addResponseTransform have throw error function
what do you suggest me? I have a way to fix it that I move throw error into each of functions which use API
ie.
The text was updated successfully, but these errors were encountered: