Conditions | 2 |
Paths | 2 |
Total Lines | 21 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
17 | public function __invoke($controller = null, $method = null) |
||
18 | { |
||
19 | if ($controller === null) { |
||
20 | $this->stdio->errln('<<red>>Controller is needed<<reset>>'); |
||
21 | return Status::USAGE; |
||
22 | } |
||
23 | |||
24 | $argv = $this->context->argv->get(); |
||
25 | array_shift($argv); |
||
26 | array_shift($argv); |
||
27 | array_shift($argv); |
||
28 | array_shift($argv); |
||
29 | $arguments = implode(' ', $argv); |
||
30 | |||
31 | $console = FCPATH . 'index.php'; |
||
32 | $this->stdio->outln( |
||
33 | "<<green>>php {$console} {$controller} {$method} {$arguments}<<reset>>" |
||
34 | ); |
||
35 | passthru("php {$console} {$controller} {$method} {$arguments}"); |
||
36 | $this->stdio->outln(''); |
||
37 | } |
||
38 | } |
||
39 |