aboutsummaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
authorAlex <zuedev@gmail.com>2025-03-23 11:25:33 +0000
committerAlex <zuedev@gmail.com>2025-03-23 11:25:33 +0000
commitd817a4dfe59cdf778454396a3f938ee4af95981c (patch)
tree22b4e9a3f5d5202f62569219ce1aa5dec1f29d8c /README.md
parent6601749134b506a3e826b335a67d7d18d2b276d5 (diff)
downloadzue.dev-d817a4dfe59cdf778454396a3f938ee4af95981c.tar
zue.dev-d817a4dfe59cdf778454396a3f938ee4af95981c.tar.gz
zue.dev-d817a4dfe59cdf778454396a3f938ee4af95981c.tar.bz2
zue.dev-d817a4dfe59cdf778454396a3f938ee4af95981c.tar.xz
zue.dev-d817a4dfe59cdf778454396a3f938ee4af95981c.zip
Refactor `route` function for improved performance and error handling
- Normalized URL path by removing trailing slashes for consistent matching. - Added proper 404 response when a route is not found, including the requested path in the error message. - Enhanced error handling to return a 500 Internal Server Error for unexpected exceptions. - Prepared for potential optimization by suggesting the use of a `Map` for faster route lookups. - Improved code readability and maintainability.
Diffstat (limited to 'README.md')
0 files changed, 0 insertions, 0 deletions