Use Coroutine::create() instead of short name method

This commit is contained in:
huangzhhui 2019-09-18 00:58:13 +08:00
parent 6b19091737
commit 0e25af3d3e

View File

@ -12,6 +12,7 @@ declare(strict_types=1);
namespace Hyperf\Utils\Coroutine;
use Hyperf\Utils\Coroutine;
use Swoole\Coroutine\Channel;
class Concurrent
@ -45,7 +46,7 @@ class Concurrent
}
}
go(function () use ($callable) {
Coroutine::create(function () use ($callable) {
$callable();
$this->channel->pop($this->timeout);
});