0
0
mirror of https://github.com/go-gitea/gitea.git synced 2025-11-02 00:27:24 +01:00
This commit is contained in:
wxiaoguang 2025-10-30 02:14:25 +08:00
parent 2b4d53a219
commit a758ffc0cc
4 changed files with 6 additions and 6 deletions

View File

@ -36,7 +36,7 @@ func (repo *Repository) ResolveReference(name string) (string, error) {
// GetRefCommitID returns the last commit ID string of given reference (branch or tag).
func (repo *Repository) GetRefCommitID(name string) (string, error) {
batch, cancel, err := repo.CatFileBatch(repo.Ctx, false) // test
batch, cancel, err := repo.CatFileBatch(repo.Ctx, true) // test
if err != nil {
return "", err
}
@ -67,7 +67,7 @@ func (repo *Repository) IsCommitExist(name string) bool {
}
func (repo *Repository) getCommit(id ObjectID) (*Commit, error) {
batch, cancel, err := repo.CatFileBatch(repo.Ctx, false) // test
batch, cancel, err := repo.CatFileBatch(repo.Ctx, true) // test
if err != nil {
return nil, err
}
@ -151,7 +151,7 @@ func (repo *Repository) ConvertToGitID(commitID string) (ObjectID, error) {
}
}
batch, cancel, err := repo.CatFileBatch(repo.Ctx, false) // test
batch, cancel, err := repo.CatFileBatch(repo.Ctx, true) // test
if err != nil {
return nil, err
}

View File

@ -10,7 +10,7 @@ import (
)
func (repo *Repository) getTree(id ObjectID) (*Tree, error) {
batch, cancel, err := repo.CatFileBatch(repo.Ctx, true)
batch, cancel, err := repo.CatFileBatch(repo.Ctx, false)
if err != nil {
return nil, err
}

View File

@ -36,7 +36,7 @@ func (te *TreeEntry) Size() int64 {
return te.size
}
batch, cancel, err := te.ptree.repo.CatFileBatch(te.ptree.repo.Ctx, true)
batch, cancel, err := te.ptree.repo.CatFileBatch(te.ptree.repo.Ctx, false)
if err != nil {
log.Debug("error whilst reading size for %s in %s. Error: %v", te.ID.String(), te.ptree.repo.Path, err)
return 0

View File

@ -35,7 +35,7 @@ func (t *Tree) ListEntries() (Entries, error) {
}
if t.repo != nil {
batch, cancel, err := t.repo.CatFileBatch(t.repo.Ctx, true)
batch, cancel, err := t.repo.CatFileBatch(t.repo.Ctx, false)
if err != nil {
return nil, err
}