Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitaly.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'internal/git/localrepo/objects.go')
-rw-r--r--internal/git/localrepo/objects.go9
1 files changed, 4 insertions, 5 deletions
diff --git a/internal/git/localrepo/objects.go b/internal/git/localrepo/objects.go
index 312b3f593..e80909edf 100644
--- a/internal/git/localrepo/objects.go
+++ b/internal/git/localrepo/objects.go
@@ -12,7 +12,6 @@ import (
"gitlab.com/gitlab-org/gitaly/internal/command"
"gitlab.com/gitlab-org/gitaly/internal/git"
"gitlab.com/gitlab-org/gitaly/internal/git/catfile"
- "gitlab.com/gitlab-org/gitaly/internal/git/log"
"gitlab.com/gitlab-org/gitaly/internal/helper/text"
"gitlab.com/gitlab-org/gitaly/proto/go/gitalypb"
)
@@ -227,20 +226,20 @@ func (repo *Repo) ReadCommit(ctx context.Context, revision git.Revision, opts ..
opt(&cfg)
}
- c, err := catfile.New(ctx, repo.gitCmdFactory, repo)
+ c, err := repo.catfileCache.BatchProcess(ctx, repo)
if err != nil {
return nil, err
}
var commit *gitalypb.GitCommit
if cfg.withTrailers {
- commit, err = log.GetCommitCatfileWithTrailers(ctx, repo.gitCmdFactory, repo, c, revision)
+ commit, err = catfile.GetCommitWithTrailers(ctx, repo.gitCmdFactory, repo, c, revision)
} else {
- commit, err = log.GetCommitCatfile(ctx, c, revision)
+ commit, err = catfile.GetCommit(ctx, c, revision)
}
if err != nil {
- if log.IsNotFound(err) {
+ if catfile.IsNotFound(err) {
return nil, ErrObjectNotFound
}
return nil, err