mirror of
https://github.com/bitinflow/expose.git
synced 2026-03-13 13:35:54 +00:00
Fix regression issue and readd basic auth support (#328)
This commit is contained in:
@@ -16,13 +16,18 @@ class Configuration
|
||||
/** @var string|null */
|
||||
protected $auth;
|
||||
|
||||
public function __construct(string $host, int $port, ?string $auth = null)
|
||||
/** @var string|null */
|
||||
protected $basicAuth;
|
||||
|
||||
public function __construct(string $host, int $port, ?string $auth = null, ?string $basicAuth = null)
|
||||
{
|
||||
$this->serverHost = $this->host = $host;
|
||||
|
||||
$this->port = $port;
|
||||
|
||||
$this->auth = $auth;
|
||||
|
||||
$this->basicAuth = $basicAuth;
|
||||
}
|
||||
|
||||
public function host(): string
|
||||
@@ -45,6 +50,11 @@ class Configuration
|
||||
return $this->auth;
|
||||
}
|
||||
|
||||
public function basicAuth(): ?string
|
||||
{
|
||||
return $this->basicAuth;
|
||||
}
|
||||
|
||||
public function port(): int
|
||||
{
|
||||
return intval($this->port);
|
||||
|
||||
Reference in New Issue
Block a user