f424bfd7 by Adam Heath

When a site is found that matches a full url, and the baseUrl ends with

a '/', then remove that when adjusting to the configured site.
1 parent a09fbb8e
......@@ -95,6 +95,10 @@ export const getUrl = async(url: string) => {
if (url.startsWith(baseUrl)) {
return getSitePage(site, url.substring(baseUrl.length))
}
if (url.startsWith(baseUrl)) {
const newUrl = url.substring(baseUrl[ baseUrl.length - 1 ] === '/' ? baseUrl.length - 1 : baseUrl.length)
return getSitePage(site, newUrl)
}
}
return getSitePage('default', url)
}
......