From 8f499d8f85cf077d6afd5e9246547e9365c45ff8 Mon Sep 17 00:00:00 2001 From: Niklas Date: Wed, 3 Feb 2021 15:00:40 +0100 Subject: [PATCH] fixed crash when lego is disabled --- internal/cooldns.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/internal/cooldns.go b/internal/cooldns.go index cebf855..5170efb 100644 --- a/internal/cooldns.go +++ b/internal/cooldns.go @@ -76,7 +76,7 @@ func createServer(zones zoneMap, config config, aclList map[string]*net.IPNet, b } // Check if it is a ACME DNS-01 challange - if handleACMERequest(w, r, acmeList) { + if config.Lego.Enable && handleACMERequest(w, r, acmeList) { return } @@ -112,7 +112,7 @@ func createServer(zones zoneMap, config config, aclList map[string]*net.IPNet, b } // Check if it is a ACME DNS-01 challange - if handleACMERequest(w, r, acmeList) { + if config.Lego.Enable && handleACMERequest(w, r, acmeList) { return }