Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
open-webui
Commits
91bc65c7
Commit
91bc65c7
authored
Jun 11, 2024
by
Timothy J. Baek
Browse files
fix
parent
a91db7f7
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
2 deletions
+5
-2
backend/apps/webui/routers/tools.py
backend/apps/webui/routers/tools.py
+2
-1
src/lib/components/workspace/Tools.svelte
src/lib/components/workspace/Tools.svelte
+3
-1
No files found.
backend/apps/webui/routers/tools.py
View file @
91bc65c7
...
@@ -172,6 +172,7 @@ async def delete_toolkit_by_id(request: Request, id: str, user=Depends(get_admin
...
@@ -172,6 +172,7 @@ async def delete_toolkit_by_id(request: Request, id: str, user=Depends(get_admin
if
result
:
if
result
:
TOOLS
=
request
.
app
.
state
.
TOOLS
TOOLS
=
request
.
app
.
state
.
TOOLS
del
TOOLS
[
id
]
if
id
in
TOOLS
:
del
TOOLS
[
id
]
return
result
return
result
src/lib/components/workspace/Tools.svelte
View file @
91bc65c7
...
@@ -166,7 +166,9 @@
...
@@ -166,7 +166,9 @@
<button
<button
class="self-center w-fit text-sm px-2 py-2 dark:text-gray-300 dark:hover:text-white hover:bg-black/5 dark:hover:bg-white/5 rounded-xl"
class="self-center w-fit text-sm px-2 py-2 dark:text-gray-300 dark:hover:text-white hover:bg-black/5 dark:hover:bg-white/5 rounded-xl"
type="button"
type="button"
on:click={async () => {
on:click={async (e) => {
e.stopPropagation();
const res = await deleteToolById(localStorage.token, tool.id).catch((error) => {
const res = await deleteToolById(localStorage.token, tool.id).catch((error) => {
toast.error(error);
toast.error(error);
return null;
return null;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment