From b2618e1ba88348e82c5f9374e3b3e5c8bdb83221 Mon Sep 17 00:00:00 2001 From: Branden J Brown Date: Fri, 2 Feb 2024 18:54:10 -0600 Subject: [PATCH] go home when game is gone --- site/src/App.vue | 3 +++ 1 file changed, 3 insertions(+) diff --git a/site/src/App.vue b/site/src/App.vue index a7bc93d..452cbe1 100644 --- a/site/src/App.vue +++ b/site/src/App.vue @@ -45,6 +45,9 @@ watchEffect(() => { if (data.value == null) { game.value = null; dealer.value = null; + if (window.location.pathname.includes('game/')) { + history.replaceState(null, '', window.origin); + } return; } const m = JSON.parse(data.value) as Game | GameStart;