Skip to content

Commit 790caec

Browse files
committed
Fix bug
1 parent e40369c commit 790caec

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

modules/git/commit_info_gogit.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,8 @@ func (tes Entries) GetCommitsInfo(ctx context.Context, gitRepo *Repository, repo
8686
var treeCommit *Commit
8787
if treePath == "" {
8888
treeCommit = commit
89+
} else {
90+
treeCommit = revs[""]
8991
}
9092
return commitsInfo, treeCommit, nil
9193
}

modules/git/commit_info_nogogit.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,8 @@ func (tes Entries) GetCommitsInfo(ctx context.Context, gitRepo *Repository, repo
7777
var treeCommit *Commit
7878
if treePath == "" {
7979
treeCommit = commit
80+
} else {
81+
treeCommit = revs[""]
8082
}
8183
return commitsInfo, treeCommit, nil
8284
}

0 commit comments

Comments
 (0)