| Conditions | 2 |
| Paths | 1 |
| Total Lines | 19 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 16 | public function render() |
||
| 17 | { |
||
| 18 | $this->initPlainInput(); |
||
| 19 | |||
| 20 | $this->prepend('<i class="fa fa-pencil fa-fw"></i>') |
||
| 21 | ->defaultAttribute('type', 'text') |
||
| 22 | ->defaultAttribute('id', $this->id) |
||
| 23 | ->defaultAttribute('name', $this->elementName ?: $this->formatName($this->column)) |
||
|
|
|||
| 24 | ->defaultAttribute('value', old($this->column, $this->value())) |
||
| 25 | ->defaultAttribute('class', 'form-control '.$this->getElementClassString()) |
||
| 26 | ->defaultAttribute('placeholder', $this->getPlaceholder()); |
||
| 27 | |||
| 28 | $this->addVariables([ |
||
| 29 | 'prepend' => $this->prepend, |
||
| 30 | 'append' => $this->append, |
||
| 31 | ]); |
||
| 32 | |||
| 33 | return parent::render(); |
||
| 34 | } |
||
| 35 | |||
| 46 |
If a method or function can return multiple different values and unless you are sure that you only can receive a single value in this context, we recommend to add an additional type check:
If this a common case that PHP Analyzer should handle natively, please let us know by opening an issue.