From 0625e19f16a434604f9bb50b76baed2ca8889ffc Mon Sep 17 00:00:00 2001 From: Jon Dufresne Date: Mon, 18 Dec 2017 04:23:11 -0800 Subject: [PATCH] Call str.lower() as a method More idiomatic Python. https://github.com/python-ldap/python-ldap/pull/139 --- Lib/ldap/modlist.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Lib/ldap/modlist.py b/Lib/ldap/modlist.py index a853500..e1dfe44 100644 --- a/Lib/ldap/modlist.py +++ b/Lib/ldap/modlist.py @@ -51,9 +51,9 @@ def modifyModlist( modlist = [] attrtype_lower_map = {} for a in old_entry.keys(): - attrtype_lower_map[str.lower(a)]=a + attrtype_lower_map[a.lower()]=a for attrtype in new_entry.keys(): - attrtype_lower = str.lower(attrtype) + attrtype_lower = attrtype.lower() if attrtype_lower in ignore_attr_types: # This attribute type is ignored continue