Skip to content

Commit d83ecec

Browse files
committed
Patch for not loading InstalledVersions.php so eagerly
1 parent 759e9d1 commit d83ecec

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

compiler/build/scoper.inc.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -246,6 +246,12 @@ function (string $filePath, string $prefix, string $content): string {
246246

247247
return str_replace(sprintf('new Error(\'%s\\Foobar\\Buz', $prefix), 'new Error(\'Foobar\\Buz', $content);
248248
},
249+
function (string $filePath, string $prefix, string $content): string {
250+
if ($filePath !== 'vendor/autoload.php') {
251+
return $content;
252+
}
253+
return str_replace('/composer/InstalledVersions.php', '/composer/InstalledVersions.php.doNotLookForThis', $content);
254+
},
249255
],
250256
'exclude-namespaces' => [
251257
'PHPStan',

0 commit comments

Comments
 (0)