Skip to content

Commit e849976

Browse files
committed
Improve implementation.
1 parent ac36501 commit e849976

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

distlib/util.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1448,7 +1448,7 @@ def connect(self):
14481448
context = ssl.SSLContext(ssl.PROTOCOL_SSLv23)
14491449
if hasattr(ssl, 'OP_NO_SSLv2'):
14501450
context.options |= ssl.OP_NO_SSLv2
1451-
if hasattr(self, 'cert_file') and self.cert_file:
1451+
if getattr(self, 'cert_file', None):
14521452
context.load_cert_chain(self.cert_file, self.key_file)
14531453
kwargs = {}
14541454
if self.ca_certs:

0 commit comments

Comments
 (0)