Browse Source

Fix SetExpr failed (#9506)

for-closed-social
Lunny Xiao 4 years ago
committed by zeripath
parent
commit
3d5f31f77d
1 changed files with 4 additions and 4 deletions
  1. +4
    -4
      models/update.go

+ 4
- 4
models/update.go View File

@ -103,10 +103,10 @@ func pushUpdateDeleteTags(e Engine, repo *Repository, tags []string) error {
if _, err := e.
Where("repo_id = ? AND is_tag = ?", repo.ID, false).
In("lower_tag_name", lowerTags).
SetExpr("is_draft", true).
SetExpr("num_commits", 0).
SetExpr("sha1", "").
Update(new(Release)); err != nil {
Cols("is_draft", "num_commits", "sha1").
Update(&Release{
IsDraft: true,
}); err != nil {
return fmt.Errorf("Update: %v", err)
}

Loading…
Cancel
Save