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(app): use default error handler if onError does not handles reponse #478

Merged
merged 1 commit into from
Aug 1, 2023

Conversation

pi0
Copy link
Member

@pi0 pi0 commented Aug 1, 2023

πŸ”— Linked issue

❓ Type of change

  • πŸ“– Documentation (updates to the documentation, readme, or JSdoc annotations)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • πŸ‘Œ Enhancement (improving an existing functionality like performance)
  • ✨ New feature (a non-breaking change that adds functionality)
  • 🧹 Chore (updates to the build process or auxiliary tools and libraries)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

πŸ“š Description

When a custom onError is in place and it does not handle response, it can cause pending responses. This PR changes implementation to wait on onError and try to handle response by h3 directly if it is not handled yet.

πŸ“ Checklist

  • I have linked an issue or discussion.
  • I have updated the documentation accordingly.

@codecov
Copy link

codecov bot commented Aug 1, 2023

Codecov Report

Merging #478 (8189a42) into main (6e58103) will decrease coverage by 0.09%.
The diff coverage is 71.42%.

@@            Coverage Diff             @@
##             main     #478      +/-   ##
==========================================
- Coverage   80.09%   80.01%   -0.09%     
==========================================
  Files          27       27              
  Lines        3025     3027       +2     
  Branches      451      453       +2     
==========================================
- Hits         2423     2422       -1     
- Misses        602      605       +3     
Files Changed Coverage Ξ”
src/node.ts 83.33% <71.42%> (-2.39%) ⬇️

@pi0
Copy link
Member Author

pi0 commented Aug 1, 2023

/cc @danielroe This should be safe as we mask console errors also. I would double check on rc please have it under your radar btw too if there are any regressions.

@pi0 pi0 changed the title fix(app): use default error handler of onError does not handle reponse fix(app): use default error handler if onError does not handles reponse Aug 1, 2023
@pi0 pi0 merged commit 9a57a89 into main Aug 1, 2023
@pi0 pi0 deleted the fix/onError-opt branch August 1, 2023 12:55
@pi0 pi0 mentioned this pull request Aug 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant