Closed mxaly closed 7 years ago
Hi @mxaly it's not workaround, it's intended. You can usereturnRejectedPromiseOnError
option to do what you need.
Right, i missed that when looking at middleware options. It's probably good to mention that here: https://github.com/svrcekmichal/redux-axios-middleware/blame/master/README.md#L77 as this example made me think that reject for api error is the default behavior.
anyway, thank for help, closing:)
Hi, i'm trying to catch api error using axios-middleware server is responding with 404 however, promise is resolved instead of beeing rejected. note that it's wrapped with other promise:
this: is not working:
workaround for this is to check in then callback if there is error key
Actions are dispatched correctly to store, just problem with this promise