diff options
author | Ethan Koenig <ethantkoenig@gmail.com> | 2017-10-04 21:43:04 -0700 |
---|---|---|
committer | Lauris BH <lauris@nix.lv> | 2017-10-05 07:43:04 +0300 |
commit | aa962deec037375a7cfae3b96094becdfe48e778 (patch) | |
tree | b4322667ac85dd945c0a6aa65c96ba4fa9b96654 /models/update.go | |
parent | e1266a19c847600aceee6f16875e0384c7c0f736 (diff) | |
download | gitea-aa962deec037375a7cfae3b96094becdfe48e778.tar.gz gitea-aa962deec037375a7cfae3b96094becdfe48e778.zip |
Replace deprecated Id method with ID (#2655)
Diffstat (limited to 'models/update.go')
-rw-r--r-- | models/update.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/models/update.go b/models/update.go index 474b989bbd..62d13ce209 100644 --- a/models/update.go +++ b/models/update.go @@ -90,14 +90,14 @@ func pushUpdateDeleteTag(repo *Repository, gitRepo *git.Repository, tagName stri return fmt.Errorf("GetRelease: %v", err) } if rel.IsTag { - if _, err = x.Id(rel.ID).Delete(new(Release)); err != nil { + if _, err = x.ID(rel.ID).Delete(new(Release)); err != nil { return fmt.Errorf("Delete: %v", err) } } else { rel.IsDraft = true rel.NumCommits = 0 rel.Sha1 = "" - if _, err = x.Id(rel.ID).AllCols().Update(rel); err != nil { + if _, err = x.ID(rel.ID).AllCols().Update(rel); err != nil { return fmt.Errorf("Update: %v", err) } } @@ -161,7 +161,7 @@ func pushUpdateAddTag(repo *Repository, gitRepo *git.Repository, tagName string) if rel.IsTag && author != nil { rel.PublisherID = author.ID } - if _, err = x.Id(rel.ID).AllCols().Update(rel); err != nil { + if _, err = x.ID(rel.ID).AllCols().Update(rel); err != nil { return fmt.Errorf("Update: %v", err) } } |