diff options
author | (quasar) nebula <qznebula@protonmail.com> | 2024-05-21 08:57:30 -0300 |
---|---|---|
committer | (quasar) nebula <qznebula@protonmail.com> | 2024-05-21 08:57:30 -0300 |
commit | 7616e2095121de9c46b5b03d3253399bfca266f5 (patch) | |
tree | e8c8eb9471723bc02921dff238baf0abaa7efcc3 /src/write/build-modes/live-dev-server.js | |
parent | c5192d9ece7c94321a18ba3e02a36bc66717be3a (diff) |
write: live-dev-server: nicer 404 for no page found
Diffstat (limited to 'src/write/build-modes/live-dev-server.js')
-rw-r--r-- | src/write/build-modes/live-dev-server.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/write/build-modes/live-dev-server.js b/src/write/build-modes/live-dev-server.js index f8e75bd2..83b70d1e 100644 --- a/src/write/build-modes/live-dev-server.js +++ b/src/write/build-modes/live-dev-server.js @@ -337,7 +337,7 @@ export async function go({ if (!Object.hasOwn(urlToPageMap, pathnameKey)) { response.writeHead(404, contentTypePlain); response.end(`No page found for: ${pathnameKey}\n`); - if (loudResponses) console.log(`${requestHead} [404] ${pathname}`); + if (loudResponses) console.log(`${requestHead} [404] ${pathname} (no page)`); return; } |