From a1ebca268e1b6e069fd64558a5f3cfd403fb60b2 Mon Sep 17 00:00:00 2001 From: mcpower Date: Sat, 28 Feb 2026 23:53:59 +1100 Subject: [PATCH] Support both /files/ and /tile/ endpoints in `matchTileUrl` The lastest update seemed to revert back to the previous /files/ endpoint, so ensure both endpoints work in case they change it again in the future. --- src/core/overlay.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/overlay.ts b/src/core/overlay.ts index de6bc6f..64fda38 100644 --- a/src/core/overlay.ts +++ b/src/core/overlay.ts @@ -74,7 +74,7 @@ export function extractPixelCoords(pixelUrl: string) { export function matchTileUrl(urlStr: string) { try { const u = new URL(urlStr, location.href); - if (u.hostname !== 'backend.wplace.live' || !u.pathname.startsWith('/tile/')) return null; + if (u.hostname !== 'backend.wplace.live' || !(u.pathname.startsWith('/files/') || u.pathname.startsWith('/tile/'))) return null; const m = u.pathname.match(/\/(\d+)\/(\d+)\.png$/i); if (!m) return null; return { chunk1: parseInt(m[1], 10), chunk2: parseInt(m[2], 10) };