浏览代码

Skip GitHub driver if openssl is disabled

Jordi Boggiano 13 年之前
父节点
当前提交
b350dda0fe
共有 1 个文件被更改,包括 1 次插入1 次删除
  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);
     }
 }