This commit is contained in:
Timothy Jaeryang Baek
2025-02-12 01:22:53 -08:00
parent 431e97b03a
commit 0bec9122c1
17 changed files with 211 additions and 47 deletions
+7 -2
View File
@@ -5,7 +5,7 @@
import dayjs from 'dayjs';
import { settings, chatId, WEBUI_NAME, models } from '$lib/stores';
import { settings, chatId, WEBUI_NAME, models, config } from '$lib/stores';
import { convertMessagesToHistory, createMessagesList } from '$lib/utils';
import { getChatByShareId, cloneSharedChatById } from '$lib/apis/chats';
@@ -61,7 +61,12 @@
//////////////////////////
const loadSharedChat = async () => {
await models.set(await getModels(localStorage.token, $settings?.directConnections ?? null));
await models.set(
await getModels(
localStorage.token,
$config?.features?.enable_direct_connetions && ($settings?.directConnections ?? null)
)
);
await chatId.set($page.params.id);
chat = await getChatByShareId(localStorage.token, $chatId).catch(async (error) => {
await goto('/');