🎥 Updates stream location to be dynamic

This commit is contained in:
Rune Harlyk
2024-08-24 21:03:18 +02:00
committed by Rune Harlyk
parent cd3ad93196
commit 3ac81b376d
+2 -3
View File
@@ -1,9 +1,8 @@
<script lang="ts">
import { user } from '$lib/stores/user';
import { onDestroy } from 'svelte';
import { location } from '$lib/utilities';
import { user, location } from '$lib/stores';
let source = `//${location}/api/camera/stream?access_token=${$user.bearer_token}`;
let source = `${$location}/api/camera/stream?access_token=${$user.bearer_token}`;
onDestroy(() => (source = '#'));
</script>