only fix links on /m/

This commit is contained in:
j 2025-06-17 08:39:35 +02:00
commit a8d1e68c08

View file

@ -112,7 +112,10 @@ const clickLink = function(event) {
}
var href = a.attributes.href.value
var prefix = document.location.protocol + '//' + document.location.hostname
if (href.startsWith(prefix)) {
if (pandoraURL && href.startsWith(pandoraURL) {
href = href.slice(pandoraURL.length)
}
if (!pandoraURL && href.startsWith(prefix)) {
href = href.slice(prefix.length)
}
if (href.startsWith('/')) {