Skip to content

Commit 3502af1

Browse files
committed
fix: crash on single tag
unable to find a previous tag when there's just one and fails instead of going to the root
1 parent 8187675 commit 3502af1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

log/gitutils.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ func isCommitToNearestTag(repo *git.Repository, commit *object.Commit) bool {
8787
log.Fatal("Couldn't get latest tag...", err)
8888
}
8989

90-
if latestTag == nil && previousTag == nil {
90+
if latestTag == nil || previousTag == nil {
9191
return false
9292
}
9393

0 commit comments

Comments
 (0)