mirror of
https://github.com/flarum/framework.git
synced 2024-11-25 17:57:04 +08:00
AbstractServer: Allow omitting base path parameter
It will be inferred from the current directory instead.
This commit is contained in:
parent
cd16adfa69
commit
b5fc7b9bf5
|
@ -30,8 +30,12 @@ abstract class AbstractServer
|
|||
/**
|
||||
* @param string $path
|
||||
*/
|
||||
public function __construct($path)
|
||||
public function __construct($path = null)
|
||||
{
|
||||
if ($path === null) {
|
||||
$path = getcwd();
|
||||
}
|
||||
|
||||
$this->path = $path;
|
||||
|
||||
if (file_exists($file = $this->path.'/config.php')) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user