aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author65432021-06-28 03:37:42 +0200
committerGitHub2021-06-27 21:37:42 -0400
commitc7db7438b7ba486d3cfc02cb032bfeb8946b76af (patch)
treede74f9558ebb1c9f2003a680f2aa84629aef9f73
parente11f042a95304df1c85d6828fdf4221ecc40a448 (diff)
Fix API to return author for author on commits(#16276) (#16277)
-rw-r--r--modules/convert/git_commit.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/convert/git_commit.go b/modules/convert/git_commit.go
index 4e30ec2c0..4234e1d98 100644
--- a/modules/convert/git_commit.go
+++ b/modules/convert/git_commit.go
@@ -155,8 +155,8 @@ func ToCommit(repo *models.Repository, commit *git.Commit, userCache map[string]
URL: repo.APIURL() + "/git/commits/" + commit.ID.String(),
Author: &api.CommitUser{
Identity: api.Identity{
- Name: commit.Committer.Name,
- Email: commit.Committer.Email,
+ Name: commit.Author.Name,
+ Email: commit.Author.Email,
},
Date: commit.Author.When.Format(time.RFC3339),
},