This commit is contained in:
2020-12-15 19:04:25 +08:00
parent 84e88d9324
commit 12be26adb3
+4
View File
@@ -202,6 +202,10 @@ class Server extends Application
*/
public function onProcessListener(): void
{
$attributes = Snowflake::app()->getAttributes();
$attributes->readControllers(CONTROLLER_PATH, 'App\Http\Controllers', 'controllers');
$attributes->readControllers(SOCKET_PATH, 'App\Websocket', 'sockets');
if (!($this->baseServer instanceof \Swoole\Server)) {
return;
}