Tangled notifications browser extension

fix: match count value

moshyfawn.dev 537c137b fc83663b

verified
+1 -1
+1 -1
utils/api.ts
··· 12 12 // FIX: requires backend to return 401 when not logged in (currently returns 200 even if not logged in) 13 13 if (!response.ok) throw new Error(`HTTP ${response.status}`); 14 14 const html = await response.text(); 15 - const match = html.match(/(\d+)/); 15 + const match = html.match(/>(\d+\+?)</); 16 16 return match ? parseInt(match[1], 10) : 0; 17 17 };