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
3b112375
Commit
3b112375
authored
Jul 08, 2024
by
Jonathan Rohde
Browse files
feat(documents): commit document delete
parent
47ec2425
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
0 deletions
+1
-0
backend/apps/webui/models/documents.py
backend/apps/webui/models/documents.py
+1
-0
No files found.
backend/apps/webui/models/documents.py
View file @
3b112375
...
@@ -158,6 +158,7 @@ class DocumentsTable:
...
@@ -158,6 +158,7 @@ class DocumentsTable:
with
get_db
()
as
db
:
with
get_db
()
as
db
:
db
.
query
(
Document
).
filter_by
(
name
=
name
).
delete
()
db
.
query
(
Document
).
filter_by
(
name
=
name
).
delete
()
db
.
commit
()
return
True
return
True
except
:
except
:
return
False
return
False
...
...
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