소스 검색

Fix cache directory upgrading - do not try to remove the destination directory.

Christian Schiffler 11 년 전
부모
커밋
fc4cc79a52
1개의 변경된 파일3개의 추가작업 그리고 1개의 파일을 삭제
  1. 3 1
      src/Composer/Factory.php

+ 3 - 1
src/Composer/Factory.php

@@ -118,7 +118,9 @@ class Factory
                             @rename($child, $dir.'/'.basename($child));
                         }
                     }
-                    @rmdir($oldPath);
+                    if ($config->get('cache-dir') != $oldPath) {
+                        @rmdir($oldPath);
+                    }
                 }
             }
         }