diff --git a/src/Readline/Hoa/Protocol.php b/src/Readline/Hoa/Protocol.php index 51d064e0..922ddcbf 100644 --- a/src/Readline/Hoa/Protocol.php +++ b/src/Readline/Hoa/Protocol.php @@ -87,7 +87,7 @@ public static function getInstance(): self protected function initialize() { $root = \dirname(__DIR__, 3); - $argv0 = \realpath($_SERVER['argv'][0]); + $argv0 = isset($_SERVER['argv'][0]) ? \realpath($_SERVER['argv'][0]) : false; $cwd = 'cli' === \PHP_SAPI