diff options
author | 6543 <6543@obermui.de> | 2020-04-10 12:40:36 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-10 13:40:36 +0300 |
commit | d21b974f6c416fd1f8415265fa6425b60860d7dd (patch) | |
tree | 00ce0c3eb3ecea8b68111a60905269c086b582fd /services | |
parent | 743022116df236c0a77c020ad142a6e21b394320 (diff) | |
download | gitea-d21b974f6c416fd1f8415265fa6425b60860d7dd.tar.gz gitea-d21b974f6c416fd1f8415265fa6425b60860d7dd.zip |
Load pr Issue Poster on API too (#11033)
Diffstat (limited to 'services')
-rw-r--r-- | services/pull/merge.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/services/pull/merge.go b/services/pull/merge.go index b412e71896..2d4d9722e8 100644 --- a/services/pull/merge.go +++ b/services/pull/merge.go @@ -337,6 +337,10 @@ func rawMerge(pr *models.PullRequest, doer *models.User, mergeStyle models.Merge return "", err } + if err = pr.Issue.LoadPoster(); err != nil { + log.Error("LoadPoster: %v", err) + return "", fmt.Errorf("LoadPoster: %v", err) + } sig := pr.Issue.Poster.NewGitSig() if signArg == "" { if err := git.NewCommand("commit", fmt.Sprintf("--author='%s <%s>'", sig.Name, sig.Email), "-m", message).RunInDirTimeoutEnvPipeline(env, -1, tmpBasePath, &outbuf, &errbuf); err != nil { |