diff options
author | 6543 <6543@obermui.de> | 2020-04-10 13:26:37 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-10 14:26:37 +0300 |
commit | bc362ea3c611a94e7920a3cf4691fd108f874ef0 (patch) | |
tree | ec573e8194163a023f5480515ddb8f44f5bc4af5 /routers | |
parent | 0a2cba972a18de5b772f001d570fff96277cd808 (diff) | |
download | gitea-bc362ea3c611a94e7920a3cf4691fd108f874ef0.tar.gz gitea-bc362ea3c611a94e7920a3cf4691fd108f874ef0.zip |
remove package code.gitea.io/gitea/modules/git import out of models (#11025)
Diffstat (limited to 'routers')
-rw-r--r-- | routers/repo/issue.go | 2 | ||||
-rw-r--r-- | routers/repo/pull.go | 1 | ||||
-rw-r--r-- | routers/user/home.go | 3 |
3 files changed, 4 insertions, 2 deletions
diff --git a/routers/repo/issue.go b/routers/repo/issue.go index 0a059bf789..3655de7ed4 100644 --- a/routers/repo/issue.go +++ b/routers/repo/issue.go @@ -240,7 +240,7 @@ func issues(ctx *context.Context, milestoneID int64, isPullOption util.OptionalB return } - commitStatus[issues[i].PullRequest.ID], _ = issues[i].PullRequest.GetLastCommitStatus() + commitStatus[issues[i].PullRequest.ID], _ = pull_service.GetLastCommitStatus(issues[i].PullRequest) } } diff --git a/routers/repo/pull.go b/routers/repo/pull.go index 55b8bbb42f..ef000208f4 100644 --- a/routers/repo/pull.go +++ b/routers/repo/pull.go @@ -433,6 +433,7 @@ func PrepareViewPullInfo(ctx *context.Context, issue *models.Issue) *git.Compare return nil } ctx.Data["Divergence"] = divergence + ctx.Data["GetCommitMessages"] = pull_service.GetCommitMessages(pull) } sha, err := baseGitRepo.GetRefCommitID(pull.GetGitRefName()) diff --git a/routers/user/home.go b/routers/user/home.go index 3807025ea5..816968562f 100644 --- a/routers/user/home.go +++ b/routers/user/home.go @@ -22,6 +22,7 @@ import ( "code.gitea.io/gitea/modules/markup/markdown" "code.gitea.io/gitea/modules/setting" "code.gitea.io/gitea/modules/util" + pull_service "code.gitea.io/gitea/services/pull" "github.com/keybase/go-crypto/openpgp" "github.com/keybase/go-crypto/openpgp/armor" @@ -553,7 +554,7 @@ func Issues(ctx *context.Context) { issue.Repo = showReposMap[issue.RepoID] if isPullList { - commitStatus[issue.PullRequest.ID], _ = issue.PullRequest.GetLastCommitStatus() + commitStatus[issue.PullRequest.ID], _ = pull_service.GetLastCommitStatus(issue.PullRequest) } } |