From 9d5c9156cac682c481b58aec952b98bd260d7829 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Ml=C3=A1dek?= Date: Tue, 30 Nov 2021 23:28:50 +0100 Subject: [PATCH] [ui] fix nav bug --- ui/src/components/UpLink.svelte | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/ui/src/components/UpLink.svelte b/ui/src/components/UpLink.svelte index 8df735b..b0de712 100644 --- a/ui/src/components/UpLink.svelte +++ b/ui/src/components/UpLink.svelte @@ -12,9 +12,10 @@ const location = useLocation(); let routerTo = "#"; - - if ($location.pathname.startsWith("/browse") && to.entity) { - routerTo = `${$location.pathname},${to.entity}`; + $: { + if ($location.pathname.startsWith("/browse") && to.entity) { + routerTo = `${$location.pathname},${to.entity}`; + } }