Show More
@@ -480,22 +480,15 b' class httppeer(wireproto.wirepeer):' | |||||
480 | def _abort(self, exception): |
|
480 | def _abort(self, exception): | |
481 | raise exception |
|
481 | raise exception | |
482 |
|
482 | |||
483 | class httpspeer(httppeer): |
|
|||
484 | def __init__(self, ui, path): |
|
|||
485 | if not url.has_https: |
|
|||
486 | raise error.Abort(_('Python support for SSL and HTTPS ' |
|
|||
487 | 'is not installed')) |
|
|||
488 | httppeer.__init__(self, ui, path) |
|
|||
489 |
|
||||
490 | def instance(ui, path, create): |
|
483 | def instance(ui, path, create): | |
491 | if create: |
|
484 | if create: | |
492 | raise error.Abort(_('cannot create new http repository')) |
|
485 | raise error.Abort(_('cannot create new http repository')) | |
493 | try: |
|
486 | try: | |
494 | if path.startswith('https:'): |
|
487 | if path.startswith('https:') and not url.has_https: | |
495 | inst = httpspeer(ui, path) |
|
488 | raise error.Abort(_('Python support for SSL and HTTPS ' | |
496 | else: |
|
489 | 'is not installed')) | |
497 | inst = httppeer(ui, path) |
|
|||
498 |
|
490 | |||
|
491 | inst = httppeer(ui, path) | |||
499 | inst._fetchcaps() |
|
492 | inst._fetchcaps() | |
500 |
|
493 | |||
501 | return inst |
|
494 | return inst |
General Comments 0
You need to be logged in to leave comments.
Login now