| Conditions | 3 |
| Paths | 4 |
| Total Lines | 11 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php namespace XoopsModules\Smartobject\Form\Elements; |
||
| 26 | public function __construct($object, $key) |
||
| 27 | { |
||
| 28 | $var = $object->vars[$key]; |
||
| 29 | $control = $object->controls[$key]; |
||
| 30 | $all = isset($control['all']) ? true : false; |
||
| 31 | |||
| 32 | parent::__construct($var['form_caption'], $key, $object->getVar($key, 'e')); |
||
|
|
|||
| 33 | if ($all) { |
||
| 34 | $this->addOption('all', _ALL); |
||
| 35 | } |
||
| 36 | } |
||
| 37 | } |
||
| 38 |
Methods can only be called on objects. This check looks for methods being called on variables that have been inferred to never be objects.