diff --git a/src/Client.php b/src/Client.php index 61f1a05..ebcab94 100644 --- a/src/Client.php +++ b/src/Client.php @@ -330,10 +330,7 @@ public function process(null|int|float $timeout = 0, bool $reply = true) } $result = $this->handlers[$message->sid]($message->payload, $message->replyTo); if ($reply && $message->replyTo) { - $this->send(new Publish([ - 'subject' => $message->replyTo, - 'payload' => Payload::parse($result), - ])); + $this->publish($message->replyTo, $result); } break; }