| Conditions | 1 |
| Paths | 1 |
| Total Lines | 25 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 20 | public function __construct() |
||
| 21 | { |
||
| 22 | parent::__construct(); |
||
| 23 | |||
| 24 | $this->setDefaultController('index'); |
||
| 25 | $this->setDefaultAction('index'); |
||
| 26 | |||
| 27 | $this->add('/:module/:controller/:action/:params', [ |
||
|
|
|||
| 28 | 'module' => 1, |
||
| 29 | 'controller' => 2, |
||
| 30 | 'action' => 3, |
||
| 31 | 'params' => 4 |
||
| 32 | ])->setName('default'); |
||
| 33 | $this->add('/:module/:controller', [ |
||
| 34 | 'module' => 1, |
||
| 35 | 'controller' => 2, |
||
| 36 | 'action' => 'index', |
||
| 37 | ])->setName('default_action'); |
||
| 38 | $this->add('/:module', [ |
||
| 39 | 'module' => 1, |
||
| 40 | 'controller' => 'index', |
||
| 41 | 'action' => 'index', |
||
| 42 | ])->setName('default_controller'); |
||
| 43 | |||
| 44 | } |
||
| 45 | |||
| 63 |
Methods can only be called on objects. This check looks for methods being called on variables that have been inferred to never be objects.