This commit is contained in:
Timothy Jaeryang Baek
2026-08-10 21:58:12 -06:00
parent b74c144c96
commit 2a45fa04cb
@@ -1,6 +1,7 @@
<script lang="ts">
import { toast } from 'svelte-sonner';
import { createEventDispatcher, onMount, getContext, tick } from 'svelte';
import { v4 as uuidv4 } from 'uuid';
import { getModels as _getModels } from '$lib/apis';
import type { Writable } from 'svelte/store';
import type { i18n as i18nType } from 'i18next';
@@ -102,7 +103,7 @@
const addTerminalConnection = (server: TerminalConnection) => {
terminalConnections = [
...terminalConnections,
{ ...server, id: server.id ?? crypto.randomUUID() }
{ ...server, id: server.id ?? crypto.randomUUID?.() ?? uuidv4() }
];
saveTerminalServers();
};