URL: https://github.com/freeipa/freeipa/pull/406
Author: MartinBasti
 Title: #406: _resolve_records: fix assert, nameserver_ip can be none
Action: opened

PR body:


To pull the PR as Git branch:
git remote add ghfreeipa https://github.com/freeipa/freeipa
git fetch ghfreeipa pull/406/head:pr406
git checkout pr406
From 4b96a27037d415fee065adacc98f07239087860e Mon Sep 17 00:00:00 2001
From: Martin Basti <mba...@redhat.com>
Date: Fri, 20 Jan 2017 13:20:08 +0100
Subject: [PATCH] _resolve_records: fix assert, nameserver_ip can be none

 ipalib/util.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/ipalib/util.py b/ipalib/util.py
index 81c0e9e..1c354b6 100644
--- a/ipalib/util.py
+++ b/ipalib/util.py
@@ -600,7 +600,7 @@ def _resolve_record(owner, rtype, nameserver_ip=None, edns0=False,
     :param flag_cd: requires dnssec=True, adds flag CD
     :raise DNSException: if error occurs
-    assert isinstance(nameserver_ip, six.string_types)
+    assert isinstance(nameserver_ip, six.string_types) or nameserver_ip is None
     assert isinstance(rtype, six.string_types)
     res = dns.resolver.Resolver()
Manage your subscription for the Freeipa-devel mailing list:
Contribute to FreeIPA: http://www.freeipa.org/page/Contribute/Code

Reply via email to