From 08ff14e277500012ebab8c705cd5c275c11f9b21 Mon Sep 17 00:00:00 2001 From: stroeder Date: Sat, 18 Nov 2017 19:40:25 +0000 Subject: [PATCH] use IterableUserDict in ldap.cidict --- Lib/ldap/cidict.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Lib/ldap/cidict.py b/Lib/ldap/cidict.py index a1f8fc5..68ac6f9 100644 --- a/Lib/ldap/cidict.py +++ b/Lib/ldap/cidict.py @@ -6,19 +6,19 @@ See https://www.python-ldap.org/ for details. """ -__version__ = """$Revision: 1.15 $""" +__version__ = """$Revision: 1.16 $""" -from UserDict import UserDict +from UserDict import IterableUserDict from string import lower -class cidict(UserDict): +class cidict(IterableUserDict): """ Case-insensitive but case-respecting dictionary. """ def __init__(self,default=None): self._keys = {} - UserDict.__init__(self,{}) + IterableUserDict.__init__(self,{}) self.update(default or {}) def __getitem__(self,key): @@ -39,7 +39,7 @@ def update(self,dict): self[key] = dict[key] def has_key(self,key): - return UserDict.has_key(self,lower(key)) + return IterableUserDict.has_key(self,lower(key)) def __contains__(self,key): return self.has_key(key)