Cancel if bus not available in client

This commit is contained in:
Chris 2024-03-01 18:33:12 +01:00
parent 4cfb66756f
commit 324fa6e519
1 changed files with 1 additions and 1 deletions

View File

@ -144,7 +144,7 @@ class CommandBusClient implements CommandBusInterface
{
if (!$this->connection) {
return new Promise(function (callable $resolve, callable $canceller) {
$canceller("Not connected to command bus.");
$canceller(new \RuntimeException("Not connected to command bus."));
});
}