fix: custom home page with setting logoLink leads to 404 page

pull/3271/head
zonemeen 2 years ago
parent 47a7203258
commit d60c29f6b5

@ -166,6 +166,11 @@ export function createRouter(
const button = (e.target as Element).closest('button')
if (button) return
// temporary fix for #3264
const currentUrl = window.location
if (siteDataRef.value.themeConfig?.logoLink === currentUrl.origin)
return
const link = (e.target as Element | SVGElement).closest<
HTMLAnchorElement | SVGAElement
>('a')
@ -181,7 +186,6 @@ export function createRouter(
: link.href,
link.baseURI
)
const currentUrl = window.location
const mimeType = lookup(pathname)
// only intercept inbound links
if (

Loading…
Cancel
Save