fix ws path not work in debug dashboard

This commit is contained in:
Jack Fong 2020-01-24 19:24:01 +08:00
parent 8e422cbc5b
commit 24101e456f
2 changed files with 14 additions and 0 deletions

View File

@ -21,6 +21,9 @@ class App
/** @var string|null */ /** @var string|null */
public $host; public $host;
/** @var string|null */
public $path;
/** @var int|null */ /** @var int|null */
public $capacity = null; public $capacity = null;
@ -76,6 +79,13 @@ class App
return $this; return $this;
} }
public function setPath(string $path)
{
$this->path = $path;
return $this;
}
public function enableClientMessages(bool $enabled = true) public function enableClientMessages(bool $enabled = true)
{ {
$this->clientMessagesEnabled = $enabled; $this->clientMessagesEnabled = $enabled;

View File

@ -71,6 +71,10 @@ class ConfigAppProvider implements AppProvider
$app->setHost($appAttributes['host']); $app->setHost($appAttributes['host']);
} }
if (isset($appAttributes['path'])) {
$app->setPath($appAttributes['path']);
}
$app $app
->enableClientMessages($appAttributes['enable_client_messages']) ->enableClientMessages($appAttributes['enable_client_messages'])
->enableStatistics($appAttributes['enable_statistics']) ->enableStatistics($appAttributes['enable_statistics'])