Passed
Push — master ( 849c84...3dbed7 )
by Bruno
02:22
created

RenderableMaterializeTrait   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 8
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
eloc 4
c 1
b 0
f 1
dl 0
loc 8
rs 10
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A editable() 0 6 1
1
<?php
2
3
namespace Formularium\Frontend\Materialize;
4
5
use Formularium\Field;
6
use Formularium\HTMLElement;
7
8
trait RenderableMaterializeTrait
9
{
10
    public function editable($value, Field $field, HTMLElement $previous): HTMLElement
11
    {
12
        /** @var HTMLElement $base */
13
        $base = $this->_editable($value, $field, $previous);
0 ignored issues
show
Bug introduced by
The method _editable() does not exist on Formularium\Frontend\Mat...derableMaterializeTrait. Did you maybe mean editable()? ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-call  annotation

13
        /** @scrutinizer ignore-call */ 
14
        $base = $this->_editable($value, $field, $previous);

This check looks for calls to methods that do not seem to exist on a given type. It looks for the method on the type itself as well as in inherited classes or implemented interfaces.

This is most likely a typographical error or the method has been renamed.

Loading history...
14
        $base->addAttribute('class', "input-field col s12");
15
        return HTMLElement::factory('div', ['class' => 'row'], $base);
16
    }
17
}
18