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
fc423594
Commit
fc423594
authored
Jan 13, 2024
by
Anuraag Jain
Browse files
fix: sanitized model name
parent
5c18d61d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
3 deletions
+4
-3
src/lib/components/chat/SettingsModal.svelte
src/lib/components/chat/SettingsModal.svelte
+4
-3
No files found.
src/lib/components/chat/SettingsModal.svelte
View file @
fc423594
...
...
@@ -314,8 +314,9 @@
};
const pullModelHandler = async () => {
if (modelDownloadStatus[modelTag]) {
toast.error(`Model '${modelTag}' is already in queue for downloading.`);
const sanitizedModelTag = modelTag.trim();
if (modelDownloadStatus[sanitizedModelTag]) {
toast.error(`Model '${sanitizedModelTag}' is already in queue for downloading.`);
return;
}
if (Object.keys(modelDownloadStatus).length === 3) {
...
...
@@ -326,7 +327,7 @@
modelTransferring = true;
modelDownloadQueue.push(
{ modelName:
m
odelTag },
{ modelName:
sanitizedM
odelTag },
async (data: { modelName: string; success: boolean; error?: Error }) => {
const { modelName } = data;
// Remove the downloaded model
...
...
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