Conditions | 3 |
Paths | 2 |
Total Lines | 10 |
Code Lines | 5 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
46 | public function getHandlerForCommand($command) |
||
47 | { |
||
48 | $handlers = $this->config->get('tactician.handlers', []); |
||
49 | |||
50 | if (! isset($handlers[$command]) || ! class_exists($handlers[$command])) { |
||
51 | throw MissingHandlerException::forCommand($command); |
||
52 | } |
||
53 | |||
54 | return $this->container->make($handlers[$command]); |
||
55 | } |
||
56 | } |
||
57 |