|
|
|
@@ -12,6 +12,7 @@ import ( |
|
|
|
"strconv" |
|
|
|
"strings" |
|
|
|
"time" |
|
|
|
"unicode/utf8" |
|
|
|
|
|
|
|
"code.gitea.io/gitea/models" |
|
|
|
"code.gitea.io/gitea/modules/auth" |
|
|
|
@@ -1291,7 +1292,7 @@ func paramCheckCreateInferenceJob(form auth.CreateModelArtsInferenceJobForm) err |
|
|
|
return errors.New("分支名不能为空") |
|
|
|
} |
|
|
|
|
|
|
|
if len(form.Description) > 255 { |
|
|
|
if utf8.RuneCountInString(form.Description) > 255 { |
|
|
|
log.Error("the Description length(%d) must not more than 255", form.Description) |
|
|
|
return errors.New("描述字符不能超过255个字符") |
|
|
|
} |
|
|
|
|