1
0
mirror of https://github.com/go-gitea/gitea.git synced 2024-11-04 08:17:24 -05:00

Fix API to return author for author on commits(#16276)

This commit is contained in:
6543 2021-06-28 00:15:42 +02:00 committed by GitHub
parent 9a0cd3af3b
commit 59c58553ba
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -155,8 +155,8 @@ func ToCommit(repo *models.Repository, commit *git.Commit, userCache map[string]
URL: repo.APIURL() + "/git/commits/" + commit.ID.String(), URL: repo.APIURL() + "/git/commits/" + commit.ID.String(),
Author: &api.CommitUser{ Author: &api.CommitUser{
Identity: api.Identity{ Identity: api.Identity{
Name: commit.Committer.Name, Name: commit.Author.Name,
Email: commit.Committer.Email, Email: commit.Author.Email,
}, },
Date: commit.Author.When.Format(time.RFC3339), Date: commit.Author.When.Format(time.RFC3339),
}, },