Fix storing of zero value revocation timestamp

This commit is contained in:
Jan Dittberner 2022-12-11 13:20:16 +01:00
parent 40b3219c7e
commit 9c17a6730f

View file

@ -69,12 +69,14 @@ type indexEntry struct {
func (ie *indexEntry) String() string {
var revoked, fileName string
if ie.revokedAt != nil {
if ie.revokedAt != nil && !ie.revokedAt.IsZero() {
revoked = fmt.Sprintf("%s,%s", ie.revokedAt.Format(TimeSpec), ie.revocationReason)
}
if ie.fileName == "" {
fileName = "unknown"
} else {
fileName = ie.fileName
}
return strings.Join([]string{