Skip to content

Commit 8d1ba04

Browse files
authored
fix: correct not found message when setting paths.base (#9232)
1 parent bb7285b commit 8d1ba04

2 files changed

Lines changed: 7 additions & 2 deletions

File tree

.changeset/lemon-pigs-remember.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@sveltejs/kit': patch
3+
---
4+
5+
fix: correct not found message when setting `paths.base`

packages/kit/src/exports/vite/utils.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,11 +87,11 @@ export function not_found(req, res, base) {
8787
if (type === 'text/html') {
8888
res.setHeader('Content-Type', 'text/html');
8989
res.end(
90-
`The server is configured with a public base URL of /path-base - did you mean to visit <a href="${prefixed}">${prefixed}</a> instead?`
90+
`The server is configured with a public base URL of ${base} - did you mean to visit <a href="${prefixed}">${prefixed}</a> instead?`
9191
);
9292
} else {
9393
res.end(
94-
`The server is configured with a public base URL of /path-base - did you mean to visit ${prefixed} instead?`
94+
`The server is configured with a public base URL of ${base} - did you mean to visit ${prefixed} instead?`
9595
);
9696
}
9797
}

0 commit comments

Comments
 (0)