mirror of
https://github.com/go-gitea/gitea
synced 2025-07-22 18:28:37 +00:00
Trim title before insert/update to database to match the size requirements of database (#32498)
Fix #32489
This commit is contained in:
@@ -142,6 +142,7 @@ func CreateRelease(gitRepo *git.Repository, rel *repo_model.Release, attachmentU
|
||||
return err
|
||||
}
|
||||
|
||||
rel.Title, _ = util.SplitStringAtByteN(rel.Title, 255)
|
||||
rel.LowerTagName = strings.ToLower(rel.TagName)
|
||||
if err = db.Insert(gitRepo.Ctx, rel); err != nil {
|
||||
return err
|
||||
|
Reference in New Issue
Block a user