Skip to content

Commit

Permalink
fix pageContext.urlParsed.hrefOriginal
Browse files Browse the repository at this point in the history
  • Loading branch information
brillout committed Jul 19, 2024
1 parent 8efd085 commit 9bf612b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion vike/utils/parseUrl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,10 +92,11 @@ function parseUrl(url: string, baseServer: string): UrlPrivate {
// Base URL
let { pathname, hasBaseServer } = removeBaseServer(pathnameAbsoluteWithBase, baseServer)
pathname = decodePathname(pathname)
pathnameAbsoluteWithBase = decodePathname(pathnameAbsoluteWithBase)

// More props
const href = createUrlFromComponents(origin, pathname, searchOriginal, hashOriginal)
const hrefOriginal = createUrlFromComponents(origin, pathnameOriginal, searchOriginal, hashOriginal)
const hrefOriginal = createUrlFromComponents(origin, pathnameAbsoluteWithBase, searchOriginal, hashOriginal)
const host = !origin ? null : origin.slice(protocol!.length)

assert(pathname.startsWith('/'))
Expand Down

0 comments on commit 9bf612b

Please sign in to comment.