Skip to content

Commit

Permalink
fix gogit
Browse files Browse the repository at this point in the history
  • Loading branch information
wxiaoguang committed Dec 18, 2023
1 parent 34e34df commit 3ef8d68
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions modules/git/repo_commitgraph_gogit.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (

gitealog "code.gitea.io/gitea/modules/log"

"github.com/go-git/go-git/v5/plumbing/format/commitgraph"
commitgraph_v2 "github.com/go-git/go-git/v5/plumbing/format/commitgraph/v2"
cgobject "github.com/go-git/go-git/v5/plumbing/object/commitgraph"
)

Expand All @@ -22,8 +22,8 @@ func (r *Repository) CommitNodeIndex() (cgobject.CommitNodeIndex, *os.File) {

file, err := os.Open(indexPath)
if err == nil {
var index commitgraph.Index
index, err = commitgraph.OpenFileIndex(file)
var index commitgraph_v2.Index
index, err = commitgraph_v2.OpenFileIndex(file)
if err == nil {
return cgobject.NewGraphCommitNodeIndex(index, r.gogitRepo.Storer), file
}
Expand Down

0 comments on commit 3ef8d68

Please sign in to comment.