Skip to content

Commit e3005fb

Browse files
Include check for COMPOSER_BINARY as entrypoint to script execution.
1 parent c9f43e4 commit e3005fb

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/SDK/Common/Util/ComposerHandler.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,10 @@ public static function isRunning(): bool
2323
return true;
2424
}
2525

26-
if (in_array(basename($_SERVER['argv'][0] ?? ''), ['composer', 'composer.phar'], true)) {
26+
if (
27+
($entrypoint = $_SERVER['argv'][0] ?? '') === getenv('COMPOSER_BINARY')
28+
|| in_array(basename($entrypoint), ['composer', 'composer.phar'], true)
29+
) {
2730
return true;
2831
}
2932

0 commit comments

Comments
 (0)