aboutsummaryrefslogtreecommitdiffstats
path: root/services/release/release.go
diff options
context:
space:
mode:
Diffstat (limited to 'services/release/release.go')
-rw-r--r--services/release/release.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/services/release/release.go b/services/release/release.go
index 55cc7bfe2f..e0035d42fc 100644
--- a/services/release/release.go
+++ b/services/release/release.go
@@ -195,7 +195,7 @@ func CreateNewTag(ctx context.Context, doer *user_model.User, repo *repo_model.R
// addAttachmentUUIDs accept a slice of new created attachments' uuids which will be reassigned release_id as the created release
// delAttachmentUUIDs accept a slice of attachments' uuids which will be deleted from the release
// editAttachments accept a map of attachment uuid to new attachment name which will be updated with attachments.
-func UpdateRelease(doer *user_model.User, gitRepo *git.Repository, rel *repo_model.Release,
+func UpdateRelease(ctx context.Context, doer *user_model.User, gitRepo *git.Repository, rel *repo_model.Release,
addAttachmentUUIDs, delAttachmentUUIDs []string, editAttachments map[string]string,
) error {
if rel.ID == 0 {
@@ -207,7 +207,7 @@ func UpdateRelease(doer *user_model.User, gitRepo *git.Repository, rel *repo_mod
}
rel.LowerTagName = strings.ToLower(rel.TagName)
- ctx, committer, err := db.TxContext(db.DefaultContext)
+ ctx, committer, err := db.TxContext(ctx)
if err != nil {
return err
}