summaryrefslogtreecommitdiffstats
path: root/services/repository/files/file.go
diff options
context:
space:
mode:
Diffstat (limited to 'services/repository/files/file.go')
-rw-r--r--services/repository/files/file.go7
1 files changed, 4 insertions, 3 deletions
diff --git a/services/repository/files/file.go b/services/repository/files/file.go
index ad445bb4ae..8de60c4cb8 100644
--- a/services/repository/files/file.go
+++ b/services/repository/files/file.go
@@ -12,6 +12,7 @@ import (
"time"
"code.gitea.io/gitea/models"
+ user_model "code.gitea.io/gitea/models/user"
"code.gitea.io/gitea/modules/git"
api "code.gitea.io/gitea/modules/structs"
)
@@ -81,7 +82,7 @@ func GetFileCommitResponse(repo *models.Repository, commit *git.Commit) (*api.Fi
}
// GetAuthorAndCommitterUsers Gets the author and committer user objects from the IdentityOptions
-func GetAuthorAndCommitterUsers(author, committer *IdentityOptions, doer *models.User) (authorUser, committerUser *models.User) {
+func GetAuthorAndCommitterUsers(author, committer *IdentityOptions, doer *user_model.User) (authorUser, committerUser *user_model.User) {
// Committer and author are optional. If they are not the doer (not same email address)
// then we use bogus User objects for them to store their FullName and Email.
// If only one of the two are provided, we set both of them to it.
@@ -93,7 +94,7 @@ func GetAuthorAndCommitterUsers(author, committer *IdentityOptions, doer *models
committerUser.FullName = committer.Name
}
} else {
- committerUser = &models.User{
+ committerUser = &user_model.User{
FullName: committer.Name,
Email: committer.Email,
}
@@ -106,7 +107,7 @@ func GetAuthorAndCommitterUsers(author, committer *IdentityOptions, doer *models
authorUser.FullName = author.Name
}
} else {
- authorUser = &models.User{
+ authorUser = &user_model.User{
FullName: author.Name,
Email: author.Email,
}