From 77c0edb634b5de9ade6456eb1fe93e7e8bd1ed01 Mon Sep 17 00:00:00 2001 From: Bob Halley Date: Thu, 2 Apr 2020 08:45:04 -0700 Subject: [PATCH] more delinting --- dns/rdata.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dns/rdata.py b/dns/rdata.py index f207168c..136d92a9 100644 --- a/dns/rdata.py +++ b/dns/rdata.py @@ -94,15 +94,15 @@ def _constify(o): """ Convert mutable types to immutable types. """ - if type(o) == bytearray: + if isinstance(o, bytearray): return bytes(o) - if type(o) == tuple: + if isinstance(o, tuple): try: hash(o) return o except Exception: return tuple(_constify(elt) for elt in o) - if type(o) == list: + if isinstance(o, list): return tuple(_constify(elt) for elt in o) return o -- 2.47.3