[wwwsearch-commits] r26634 - wwwsearch/mechanize/branch/mechanize-0.1.0-devel/mechanize

jjlee at codespeak.net jjlee at codespeak.net
Mon May 1 14:22:55 CEST 2006


Author: jjlee
Date: Mon May  1 14:22:54 2006
New Revision: 26634

Modified:
   wwwsearch/mechanize/branch/mechanize-0.1.0-devel/mechanize/_useragent.py
Log:
Tidy feature detection a tiny bit

Modified: wwwsearch/mechanize/branch/mechanize-0.1.0-devel/mechanize/_useragent.py
==============================================================================
--- wwwsearch/mechanize/branch/mechanize-0.1.0-devel/mechanize/_useragent.py	(original)
+++ wwwsearch/mechanize/branch/mechanize-0.1.0-devel/mechanize/_useragent.py	Mon May  1 14:22:54 2006
@@ -12,7 +12,7 @@
 """
 
 import sys
-import urllib2, httplib
+import urllib2
 import ClientCookie
 if sys.version_info[:2] >= (2, 4):
     from urllib2 import OpenerDirector, BaseHandler, HTTPErrorProcessor
@@ -139,7 +139,7 @@
                         "_proxy", "_proxy_basicauth", "_proxy_digestauth",
                         "_seek",
                         ]
-    if hasattr(httplib, 'HTTPS'):
+    if hasattr(ClientCookie, 'HTTPSHandler'):
         handler_classes["https"] = ClientCookie.HTTPSHandler
         default_schemes.append("https")
     if hasattr(ClientCookie, "HTTPRobotRulesProcessor"):


More information about the wwwsearch-commits mailing list