diff --git a/src/Threading/ThreadContext.php b/src/Threading/ThreadContext.php index fcd3efb..61c502d 100644 --- a/src/Threading/ThreadContext.php +++ b/src/Threading/ThreadContext.php @@ -76,8 +76,8 @@ abstract class ThreadContext implements ContextInterface $this->socket->read(1)->then(function ($data) { $message = ord($data); if ($message === Thread::MSG_DONE) { - $this->thread->join(); $this->deferredJoin->resolve(); + $this->thread->join(); return; }