modify plugin name

This commit is contained in:
2022-02-14 14:34:56 +08:00
parent fce7551dc3
commit 5b93689184
+7
View File
@@ -52,13 +52,20 @@ class Server extends AbstractServer
/** /**
* @param int $fd * @param int $fd
* @throws ContainerExceptionInterface
* @throws NotFoundExceptionInterface
*/ */
public function onClose(int $fd): void public function onClose(int $fd): void
{ {
$collector = $this->getContainer()->get(Sender::class); $collector = $this->getContainer()->get(Sender::class);
$fds = $this->getContainer()->get(FdCollector::class);
if (!$collector->isEstablished($fd)) { if (!$collector->isEstablished($fd)) {
return; return;
} }
$fds->remove($fd);
if ($this->callback instanceof OnCloseInterface) { if ($this->callback instanceof OnCloseInterface) {
$this->callback->onClose($fd); $this->callback->onClose($fd);
} }