瀏覽代碼

fix: share chat modal

Timothy J. Baek 1 年之前
父節點
當前提交
eca59f759d
共有 1 個文件被更改,包括 4 次插入2 次删除
  1. 4 2
      src/lib/components/chat/ShareChatModal.svelte

+ 4 - 2
src/lib/components/chat/ShareChatModal.svelte

@@ -73,8 +73,10 @@
 	export let show = false;
 	export let show = false;
 
 
 	onMount(async () => {
 	onMount(async () => {
-		chat = await getChatById(localStorage.token, $chatId);
-		console.log(chat);
+		chatId.subscribe(async (value) => {
+			chat = await getChatById(localStorage.token, value);
+			console.log(chat);
+		});
 	});
 	});
 </script>
 </script>