denoland / std

The Deno Standard Library
https://jsr.io/@std
MIT License
3.17k stars 621 forks source link

refactor(http): inline `serveFallback()` util #5917

Closed kt3k closed 2 months ago

kt3k commented 2 months ago

This PR inlines serveFallback util in file_server.

This PR also removes the handling of URIError. This error can't happen now because url is taken from request.url which should be always a valid url.

This prepares for the implementation of #5875

codecov[bot] commented 2 months ago

Codecov Report

Attention: Patch coverage is 0% with 3 lines in your changes missing coverage. Please review.

Project coverage is 96.25%. Comparing base (fb79076) to head (523fa8d). Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
http/file_server.ts 0.00% 3 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #5917 +/- ## ========================================== + Coverage 96.24% 96.25% +0.01% ========================================== Files 491 491 Lines 39443 39436 -7 Branches 5811 5810 -1 ========================================== - Hits 37961 37959 -2 + Misses 1438 1433 -5 Partials 44 44 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.