From b9a596a3b57cf9455ee16f30bb78d55467a3565f Mon Sep 17 00:00:00 2001 From: Dicken Date: Fri, 12 Jun 2026 17:17:09 +0200 Subject: [PATCH] =?UTF-8?q?fix:=20mobile=20Subdomains=20normalisieren=20(m?= =?UTF-8?q?.bild.de=20=E2=86=92=20www.bild.de)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/tools/paywallkiller.jsx | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/frontend/src/tools/paywallkiller.jsx b/frontend/src/tools/paywallkiller.jsx index f164f1d..beababf 100644 --- a/frontend/src/tools/paywallkiller.jsx +++ b/frontend/src/tools/paywallkiller.jsx @@ -15,8 +15,21 @@ export default function PaywallKiller() { const inputRef = useRef(null); function getTargetUrl() { - const url = inputUrl.trim(); - return url.startsWith('http') ? url : 'https://' + url; + let url = inputUrl.trim(); + if (!url.startsWith('http')) url = 'https://' + url; + // Mobile Subdomains auf Desktop normalisieren (m.bild.de → www.bild.de) + // damit archive.ph den richtigen Snapshot findet + try { + const u = new URL(url); + if (u.hostname.startsWith('m.')) { + u.hostname = 'www.' + u.hostname.slice(2); + url = u.toString(); + } else if (u.hostname.startsWith('mobile.')) { + u.hostname = 'www.' + u.hostname.slice(7); + url = u.toString(); + } + } catch {} + return url; } function handleSearch() {