Conditions | 5 |
Paths | 2 |
Total Lines | 13 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Tests | 7 |
CRAP Score | 5 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
38 | 3 | public function dispatch(object $event, ?string $eventName = null): object |
|
39 | { |
||
40 | if ( |
||
41 | 3 | $this->configurationTableName |
|
42 | 3 | && $event instanceof ConsoleCommandEvent |
|
43 | && ( |
||
44 | 3 | $event->getCommand() instanceof ValidateSchemaCommand |
|
45 | 3 | || $event->getCommand() instanceof UpdateCommand |
|
46 | )) { |
||
47 | 2 | $this->enabled = true; |
|
48 | } |
||
49 | |||
50 | 3 | return $event; |
|
51 | } |
||
53 |