aboutsummaryrefslogtreecommitdiffstats
path: root/routers/repo/release.go
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2019-10-01 00:10:00 +0800
committerGitHub <noreply@github.com>2019-10-01 00:10:00 +0800
commit3249c0ccba5b3082fe60f4b571159016db6d57d7 (patch)
tree300f96f564ad68833a439c765defe347fbbcb350 /routers/repo/release.go
parentecd4bfd2844346e0f2af795d9815e2224556ef47 (diff)
downloadgitea-3249c0ccba5b3082fe60f4b571159016db6d57d7.tar.gz
gitea-3249c0ccba5b3082fe60f4b571159016db6d57d7.zip
Extract actions on deletereleasebyid from models to release service (#8219)
* extract actions on deletereleasebyid from models to release service * fix tests
Diffstat (limited to 'routers/repo/release.go')
-rw-r--r--routers/repo/release.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/routers/repo/release.go b/routers/repo/release.go
index 95423a92b2..0ab8450bd5 100644
--- a/routers/repo/release.go
+++ b/routers/repo/release.go
@@ -291,7 +291,7 @@ func EditReleasePost(ctx *context.Context, form auth.EditReleaseForm) {
// DeleteRelease delete a release
func DeleteRelease(ctx *context.Context) {
- if err := models.DeleteReleaseByID(ctx.QueryInt64("id"), ctx.User, true); err != nil {
+ if err := releaseservice.DeleteReleaseByID(ctx.QueryInt64("id"), ctx.User, true); err != nil {
ctx.Flash.Error("DeleteReleaseByID: " + err.Error())
} else {
ctx.Flash.Success(ctx.Tr("repo.release.deletion_success"))