forked from TrueCloudLab/certificates
Remove use of time.Duration.Abs
time.Duration.Abs() was added in Go 1.19
This commit is contained in:
parent
89c8c6d0a0
commit
2d582e5694
1 changed files with 1 additions and 1 deletions
|
@ -706,7 +706,7 @@ func (a *Authority) GenerateCertificateRevocationList() error {
|
||||||
// Convert our database db.RevokedCertificateInfo types into the pkix
|
// Convert our database db.RevokedCertificateInfo types into the pkix
|
||||||
// representation ready for the CAS to sign it
|
// representation ready for the CAS to sign it
|
||||||
var revokedCertificates []pkix.RevokedCertificate
|
var revokedCertificates []pkix.RevokedCertificate
|
||||||
skipExpiredTime := now.Add(-config.DefaultCRLExpiredDuration.Abs())
|
skipExpiredTime := now.Add(-config.DefaultCRLExpiredDuration)
|
||||||
for _, revokedCert := range *revokedList {
|
for _, revokedCert := range *revokedList {
|
||||||
// skip expired certificates
|
// skip expired certificates
|
||||||
if !revokedCert.ExpiresAt.IsZero() && revokedCert.ExpiresAt.Before(skipExpiredTime) {
|
if !revokedCert.ExpiresAt.IsZero() && revokedCert.ExpiresAt.Before(skipExpiredTime) {
|
||||||
|
|
Loading…
Reference in a new issue