From de20fa958276bc75f947ce6705f8c07f47d0a2de Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=90=91=E6=9E=97?= Date: Thu, 6 Jan 2022 19:05:15 +0800 Subject: [PATCH] =?UTF-8?q?Revert=20"=E6=94=B9=E5=90=8D"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This reverts commit fdf58326 --- ServerCommand.php | 4 ++-- ServerManager.php | 2 -- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/ServerCommand.php b/ServerCommand.php index 11d5d54..fb63f01 100644 --- a/ServerCommand.php +++ b/ServerCommand.php @@ -4,15 +4,14 @@ declare(strict_types=1); namespace Server; -use Note\Inject; use Exception; use Kiri\Abstracts\Config; use Kiri\Events\EventDispatch; use Kiri\Exception\ConfigException; use Kiri\Kiri; +use Note\Inject; use Psr\Container\ContainerExceptionInterface; use Psr\Container\NotFoundExceptionInterface; -use Server\Events\OnServerBeforeStart; use Swoole\Coroutine; use Symfony\Component\Console\Command\Command; use Symfony\Component\Console\Input\InputArgument; @@ -87,6 +86,7 @@ class ServerCommand extends Command private function configure_set() { $enable_coroutine = Config::get('servers.settings.enable_coroutine', false); + Config::set('servers.settings.enable_coroutine', true); if ($enable_coroutine != true) { return; } diff --git a/ServerManager.php b/ServerManager.php index 2ba4526..28bd28c 100644 --- a/ServerManager.php +++ b/ServerManager.php @@ -136,7 +136,6 @@ class ServerManager extends Component * @throws ConfigException * @throws ContainerExceptionInterface * @throws NotFoundExceptionInterface - * @throws ReflectionException */ public function initBaseServer($configs, int $daemon = 0): void { @@ -197,7 +196,6 @@ class ServerManager extends Component * @throws ConfigException * @throws ContainerExceptionInterface * @throws NotFoundExceptionInterface - * @throws ReflectionException * @throws Exception */ private function startListenerHandler(ServerManager $context, array $config, int $daemon = 0)