| Conditions | 1 |
| Paths | 1 |
| Total Lines | 13 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php declare(strict_types=1); |
||
| 17 | public static function forCommand(string $commandClass, int $code = 0, Throwable $previous = null): self |
||
| 18 | { |
||
| 19 | $message = sprintf( |
||
| 20 | "I cannot find a handler for the command `%s`. You should check those possibilities: %s |
||
| 21 | - You forgot to inject a CommandHandlerMap to the CommandBus. %s |
||
| 22 | - You forgot to add the couple command/handler to your CommandHandlerMap.", |
||
| 23 | $commandClass, |
||
| 24 | PHP_EOL, |
||
| 25 | PHP_EOL |
||
| 26 | ); |
||
| 27 | |||
| 28 | return new self($message, $code, $previous); |
||
| 29 | } |
||
| 30 | } |
||
| 31 |