From 835927f5d57036507a6e058b82368bcea29844a2 Mon Sep 17 00:00:00 2001 From: xenolf Date: Sun, 18 Oct 2015 00:25:46 +0200 Subject: [PATCH] Clean-up ugly zero time check --- acme/crypto.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/acme/crypto.go b/acme/crypto.go index 8be4c76a..9e8f3f0b 100644 --- a/acme/crypto.go +++ b/acme/crypto.go @@ -60,8 +60,7 @@ func generateDerCert(privKey *rsa.PrivateKey, expiration time.Time, domain strin return nil, err } - zero := time.Time{} - if expiration == zero { + if expiration.IsZero() { expiration = time.Now().Add(365) }