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
OpenDAS
ollama
Commits
c2e3b891
Unverified
Commit
c2e3b891
authored
Nov 29, 2023
by
Timothy Jaeryang Baek
Committed by
GitHub
Nov 29, 2023
Browse files
fix: disable ':' in tag names (#1280)
Co-authored-by: rootedbox
parent
cde31cb2
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
0 deletions
+5
-0
server/routes.go
server/routes.go
+5
-0
No files found.
server/routes.go
View file @
c2e3b891
...
...
@@ -416,6 +416,11 @@ func CreateModelHandler(c *gin.Context) {
return
}
if
strings
.
Count
(
req
.
Name
,
":"
)
>
1
{
c
.
AbortWithStatusJSON
(
http
.
StatusBadRequest
,
gin
.
H
{
"error"
:
"':' (colon) is not allowed in tag names"
})
return
}
if
req
.
Path
==
""
&&
req
.
Modelfile
==
""
{
c
.
AbortWithStatusJSON
(
http
.
StatusBadRequest
,
gin
.
H
{
"error"
:
"path or modelfile are required"
})
return
...
...
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