瀏覽代碼

Update URLs for bitbucket as well

Jordi Boggiano 10 年之前
父節點
當前提交
d5bdf4be28
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/Composer/Installer.php

+ 1 - 1
src/Composer/Installer.php

@@ -970,7 +970,7 @@ class Installer
                 $package->setSourceUrl($newPackage->getSourceUrl());
                 // only update dist url for github dists as they use a combination of dist url + dist reference to install
                 // but for other urls this is ambiguous and could result in bad outcomes
-                if (preg_match('{^https?://(api\.)?github\.com/}', $newPackage->getDistUrl())) {
+                if (preg_match('{^https?://(?:(?:www\.)?bitbucket\.org|(api\.)?github\.com)/}', $newPackage->getDistUrl())) {
                     $package->setDistUrl($newPackage->getDistUrl());
                 }
             }