summaryrefslogtreecommitdiffstats
path: root/Lib/urllib2.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/urllib2.py')
-rw-r--r--Lib/urllib2.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/Lib/urllib2.py b/Lib/urllib2.py
index 8d44a0d..4321c36 100644
--- a/Lib/urllib2.py
+++ b/Lib/urllib2.py
@@ -428,9 +428,8 @@ def build_opener(*handlers):
If any of the handlers passed as arguments are subclasses of the
default handlers, the default handlers will not be used.
"""
- import types
def isclass(obj):
- return isinstance(obj, types.ClassType) or hasattr(obj, "__bases__")
+ return isinstance(obj, type) or hasattr(obj, "__bases__")
opener = OpenerDirector()
default_classes = [ProxyHandler, UnknownHandler, HTTPHandler,