diff --git a/src/pages/channel/+page.svelte b/src/pages/channel/+page.svelte index f26196736..d9d8f0b46 100644 --- a/src/pages/channel/+page.svelte +++ b/src/pages/channel/+page.svelte @@ -4,7 +4,10 @@ onMount(() => { const id = $page.url.searchParams.get('id') + if (!id) return window.location.replace('/') const [name, country] = id.split('.') + if (!name || !country) return window.location.replace('/') + const redirectUrl = `/channels/${country}/${name}` window.location.replace(redirectUrl)