Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Have unique error messages for xhr timeouts and errors #1380

Merged
merged 1 commit into from
Sep 11, 2023

Conversation

bitcrumb
Copy link
Contributor

Both xhr.onerror and xhr.ontimeout throw the same error.

I think it would be beneficial to have both handler emit errors with a different message. This way, applications can behave differently based on the error message. Especially since there is no such thing as a unique error code do distinguish both errors.

@JakeChampion JakeChampion changed the title Change error message on timeout fix: Have unique error messages for xhr timeouts and errors Sep 11, 2023
@JakeChampion JakeChampion merged commit 7170f0b into JakeChampion:master Sep 11, 2023
2 checks passed
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 11, 2024
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