summaryrefslogtreecommitdiffstats
path: root/composer-rpm.patch
diff options
context:
space:
mode:
Diffstat (limited to 'composer-rpm.patch')
-rw-r--r--composer-rpm.patch32
1 files changed, 19 insertions, 13 deletions
diff --git a/composer-rpm.patch b/composer-rpm.patch
index 5f05a85..d63b69b 100644
--- a/composer-rpm.patch
+++ b/composer-rpm.patch
@@ -110,16 +110,22 @@ diff -up ./tests/Composer/Test/PolyfillTestCase.php.rpm ./tests/Composer/Test/Po
{
--- ./src/Composer/InstalledVersions.php.rpm 2021-06-07 08:18:59.326450774 +0200
+++ ./src/Composer/InstalledVersions.php 2021-06-07 08:19:11.525413189 +0200
-@@ -315,10 +315,9 @@
- }
- }
-
-- if (null === self::$installed) {
-- self::$installed = require __DIR__ . '/installed.php';
-+ if (null !== self::$installed) {
-+ $installed[] = self::$installed;
- }
-- $installed[] = self::$installed;
-
- return $installed;
- }
+@@ -251,7 +251,7 @@ class InstalledVersions
+ if (null === self::$installed) {
+ // only require the installed.php file if this file is loaded from its dumped location,
+ // and not from its source location in the composer/composer package, see https://github.com/composer/composer/issues/9937
+- if (substr(__DIR__, -8, 1) !== 'C') {
++ if (substr(__DIR__, -8, 1) !== 'C' && is_file(__DIR__ . '/installed.php')) {
+ self::$installed = include __DIR__ . '/installed.php';
+ } else {
+ self::$installed = array();
+@@ -324,7 +324,7 @@ class InstalledVersions
+ if (null === self::$installed) {
+ // only require the installed.php file if this file is loaded from its dumped location,
+ // and not from its source location in the composer/composer package, see https://github.com/composer/composer/issues/9937
+- if (substr(__DIR__, -8, 1) !== 'C') {
++ if (substr(__DIR__, -8, 1) !== 'C' && is_file(__DIR__ . '/installed.php')) {
+ self::$installed = require __DIR__ . '/installed.php';
+ } else {
+ self::$installed = array();
+