added fallthrough debug statements

This commit is contained in:
W Anders
2024-05-07 21:05:40 -06:00
parent 7ba656f7c3
commit a9f1df8056
+14 -2
View File
@@ -70,9 +70,21 @@ func (netboxdns *NetboxDNS) ServeDNS(
if err != nil {
return dns.RcodeServerFailure, err
}
if response.LookupResult == lookupNameError &&
netboxdns.fall.Through(qname) {
if response.LookupResult == lookupNameError {
if netboxdns.fall.Through(qname) {
logger.Debugf(
"forwarding request [%s] %q to next plugin",
dns.TypeToString[qtype],
qname,
)
return netboxdns.nextOrFailure(reqContext, respWriter, reqMsg)
} else {
logger.Debugf(
"no records for [%s] %q; fallthrough not enabled",
dns.TypeToString[qtype],
qname,
)
}
}
respMsg := &dns.Msg{