变更
This commit is contained in:
@@ -40,6 +40,10 @@ class AsyncServer implements ServerInterface
|
|||||||
#[Container(Config::class)]
|
#[Container(Config::class)]
|
||||||
public Config $config;
|
public Config $config;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @var Kiri\Di\Container
|
||||||
|
*/
|
||||||
#[Container(ContainerInterface::class)]
|
#[Container(ContainerInterface::class)]
|
||||||
public ContainerInterface $container;
|
public ContainerInterface $container;
|
||||||
|
|
||||||
@@ -129,7 +133,7 @@ class AsyncServer implements ServerInterface
|
|||||||
$this->onEventListen($this->server, Config::get('server.events', []));
|
$this->onEventListen($this->server, Config::get('server.events', []));
|
||||||
$this->onEventListen($this->server, $config->events);
|
$this->onEventListen($this->server, $config->events);
|
||||||
|
|
||||||
$this->container->setBindings(ServerInterface::class, $this->server);
|
$this->container->set(ServerInterface::class, $this->server);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user