Skip to content
This repository has been archived by the owner on Jan 17, 2022. It is now read-only.

Fix error handling #4

Merged
merged 1 commit into from
Aug 21, 2020
Merged

Conversation

cinemaster
Copy link
Collaborator

Error response will be parsed by json on this line.
But error response may not return as json format, then it will be failed on some cases.

e.g. Timeout error (504), returns html
Uncaught (in promise) SyntaxError: Unexpected token < in JSON at position 0

I think should dispatch payload with response as is, then error handling should be done by app side (= onErrorMiddleware).

@Ozahata Ozahata merged commit 6c774a2 into Ozahata:master Aug 21, 2020
@cinemaster cinemaster deleted the fix-error-handling branch August 21, 2020 02:50
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants