Update deprecated function from dnspython

This commit is contained in:
David Duque
2020-07-26 01:00:17 +01:00
parent 60911515fd
commit 5e597bb536
2 changed files with 5 additions and 5 deletions
+1 -1
View File
@@ -744,7 +744,7 @@ def query_dns(qname, rtype, nxdomain='[Not Set]', at=None):
# Do the query.
try:
response = resolver.query(qname, rtype)
response = resolver.resolve(qname, rtype)
except (dns.resolver.NoNameservers, dns.resolver.NXDOMAIN, dns.resolver.NoAnswer):
# Host did not have an answer for this query; not sure what the
# difference is between the two exceptions.