From 12a401be8eeb95cfb31eafa1378b6d631591ec3a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=90=91=E6=9E=97?= Date: Mon, 14 Feb 2022 14:41:41 +0800 Subject: [PATCH] modify plugin name --- Coroutine/Http.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Coroutine/Http.php b/Coroutine/Http.php index dcf25f7..92e4d19 100644 --- a/Coroutine/Http.php +++ b/Coroutine/Http.php @@ -157,8 +157,11 @@ class Http extends Component try { $response->upgrade(); $fdCollector->set($response->fd, $response); - if (is_callable($open)) { - $open($request); + if (is_callable($handshake)) { + call_user_func($handshake, $request, $response); + if (is_callable($open)) { + $open($request); + } } while (($data = $response->recv()) instanceof Frame) { try {