diff options
Diffstat (limited to 'designate/backend/agent_backend/impl_denominator.py')
-rw-r--r-- | designate/backend/agent_backend/impl_denominator.py | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/designate/backend/agent_backend/impl_denominator.py b/designate/backend/agent_backend/impl_denominator.py index 5b350079..2b66ae52 100644 --- a/designate/backend/agent_backend/impl_denominator.py +++ b/designate/backend/agent_backend/impl_denominator.py @@ -18,7 +18,6 @@ import itertools import dns.rdata import dns.rdatatype import dns.rdataclass -import six from oslo_config import cfg from oslo_concurrency import lockutils from oslo_log import log as logging @@ -122,7 +121,7 @@ class DenominatorBackend(base.AgentBackend): def create_zone(self, zone): LOG.debug("Creating %s", zone.origin.to_text()) zone_name = zone.origin.to_text(omit_final_dot=True) - if six.PY3 and isinstance(zone_name, bytes): + if isinstance(zone_name, bytes): zone_name = zone_name.decode('utf-8') # Use SOA TTL as zone default TTL @@ -156,7 +155,7 @@ class DenominatorBackend(base.AgentBackend): def update_zone(self, zone): LOG.debug("Updating %s", zone.origin) zone_name = zone.origin.to_text(omit_final_dot=True) - if six.PY3 and isinstance(zone_name, bytes): + if isinstance(zone_name, bytes): zone_name = zone_name.decode('utf-8') soa_record = zone.find_rrset(zone.origin, dns.rdatatype.SOA) @@ -226,7 +225,7 @@ class DenominatorBackend(base.AgentBackend): for rname, ttl, rdata in zone.iterate_rdatas(): name = rname.derelativize(origin=zone.origin) name = name.to_text(omit_final_dot=True) - if six.PY3 and isinstance(name, bytes): + if isinstance(name, bytes): name = name.decode('utf-8') data = rdata.to_text(origin=zone.origin, relativize=False) |