Browse Source

Skip GitHub driver if openssl is disabled

Jordi Boggiano 13 năm trước cách đây
mục cha
commit
b350dda0fe
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      src/Composer/Repository/Vcs/GitHubDriver.php

+ 1 - 1
src/Composer/Repository/Vcs/GitHubDriver.php

@@ -146,6 +146,6 @@ class GitHubDriver implements VcsDriverInterface
      */
     public static function supports($url, $deep = false)
     {
-        return preg_match('#^(?:https?|git)://github\.com/([^/]+)/(.+?)(?:\.git)?$#', $url, $match);
+        return extension_loaded('openssl') && preg_match('#^(?:https?|git)://github\.com/([^/]+)/(.+?)(?:\.git)?$#', $url, $match);
     }
 }