From 9a6468255afd45aa172067bb2dde0d5e8be0c68f Mon Sep 17 00:00:00 2001 From: Heino <132708558+HeinoDev@users.noreply.github.com> Date: Thu, 12 Nov 2026 20:36:43 +0100 Subject: [PATCH 1/3] fix(clipboard): handle write failures --- web/src/lib/clipboard.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/src/lib/clipboard.ts b/web/src/lib/clipboard.ts index 96a6b58f5..d2d753c27 100644 --- a/web/src/lib/clipboard.ts +++ b/web/src/lib/clipboard.ts @@ -24,7 +24,7 @@ export function copyToClipboard(text: string): boolean { ok = false; } - try { void navigator.clipboard?.writeText(text); } catch { /* ignore */ } + try { void navigator.clipboard?.writeText(text).catch(() => {}); } catch { /* ignore */ } return ok; } From 96504085f99e8626826c7bcadcadf9d17cc6089e Mon Sep 17 00:00:00 2001 From: Heino <132708558+HeinoDev@users.noreply.github.com> Date: Thu, 12 Nov 2026 20:39:09 +0100 Subject: [PATCH 2/3] fix(settings): handle timer wrap --- server/util.lua | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/server/util.lua b/server/util.lua index 04cf58924..e8fc3b81f 100644 --- a/server/util.lua +++ b/server/util.lua @@ -636,7 +636,9 @@ function util.cooldownLeft(cid, key, ms) if type(cid) ~= 'string' or cid == '' then return 0 end local b = buckets[cid .. '\0c\0' .. tostring(key)] if not b then return 0 end - local left = (tonumber(ms) or 0) - (GetGameTimer() - b.last) + local since = GetGameTimer() - b.last + if since < 0 then return 0 end + local left = (tonumber(ms) or 0) - since return left > 0 and math.floor(left) or 0 end From 9edac11b9f52c3562e660ddb784b6d9621f6a428 Mon Sep 17 00:00:00 2001 From: Heino <132708558+HeinoDev@users.noreply.github.com> Date: Thu, 12 Nov 2026 20:40:24 +0100 Subject: [PATCH 3/3] fix(games): handle lobby refresh failure --- web/src/apps/_games/useOnlineLobby.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/web/src/apps/_games/useOnlineLobby.ts b/web/src/apps/_games/useOnlineLobby.ts index 31ba54554..ffee3cc14 100644 --- a/web/src/apps/_games/useOnlineLobby.ts +++ b/web/src/apps/_games/useOnlineLobby.ts @@ -128,8 +128,8 @@ export function useOnlineLobby(game: string, options: UseOnlineLobbyOptions): On const inHub = options.inLobbyScreen && !lobby && active; useEffect(() => { if (!inHub) return; - void lobbiesApi(game).then(setLobbies); - const timer = setInterval(() => { void lobbiesApi(game).then(setLobbies); }, 3000); + void lobbiesApi(game).then(setLobbies).catch(() => {}); + const timer = setInterval(() => { void lobbiesApi(game).then(setLobbies).catch(() => {}); }, 3000); return () => clearInterval(timer); }, [inHub, game]); @@ -228,7 +228,7 @@ export function useOnlineLobby(game: string, options: UseOnlineLobbyOptions): On setReadyApi(r); }, []); - const refresh = useCallback(() => { void lobbiesApi(game).then(setLobbies); }, [game]); + const refresh = useCallback(() => { void lobbiesApi(game).then(setLobbies).catch(() => {}); }, [game]); const returnToLobby = useCallback(() => { void returnToLobbyApi(game).then(r => {