From e407b9a96ee3ce2a685e89cdb536404ec8ca1cb9 Mon Sep 17 00:00:00 2001 From: vvakame Date: Fri, 9 Nov 2018 15:35:18 +0900 Subject: [PATCH] fix: Panic occured when exec --next-tag with HEAD with tag --- chglog.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chglog.go b/chglog.go index 1be130f8..d6164e8b 100644 --- a/chglog.go +++ b/chglog.go @@ -195,7 +195,7 @@ func (gen *Generator) readVersions(tags []*Tag, first string) ([]*Version, error }) // Instead of `getTags()`, assign the date to the tag - if isNext { + if isNext && len(commits) != 0 { tag.Date = commits[0].Author.Date } }