forked from open-webui/open-webui
feat: show error toast if trying to download db on external db
This commit is contained in:
parent
e91a49c455
commit
47a33acfeb
4 changed files with 21 additions and 6 deletions
|
@ -2,6 +2,7 @@
|
|||
import { downloadDatabase } from '$lib/apis/utils';
|
||||
import { onMount, getContext } from 'svelte';
|
||||
import { config } from '$lib/stores';
|
||||
import { toast } from 'svelte-sonner';
|
||||
|
||||
const i18n = getContext('i18n');
|
||||
|
||||
|
@ -32,7 +33,9 @@
|
|||
on:click={() => {
|
||||
// exportAllUserChats();
|
||||
|
||||
downloadDatabase(localStorage.token);
|
||||
downloadDatabase(localStorage.token).catch((error) => {
|
||||
toast.error(error);
|
||||
});
|
||||
}}
|
||||
>
|
||||
<div class=" self-center mr-3">
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue