We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 36a1a36 commit 7e3e5ffCopy full SHA for 7e3e5ff
src/BasePathDetector.php
@@ -21,12 +21,12 @@ class BasePathDetector
21
* The constructor.
22
*
23
* @param array $server The SERVER data to use
24
- * @param string $phpSapi The PHP_SAPI value
+ * @param string|null $phpSapi The PHP_SAPI value
25
*/
26
- public function __construct(array $server, string $phpSapi)
+ public function __construct(array $server, string $phpSapi = null)
27
{
28
$this->server = $server;
29
- $this->phpSapi = $phpSapi;
+ $this->phpSapi = $phpSapi ?? PHP_SAPI;
30
}
31
32
/**
0 commit comments