Code Duplication    Length = 9-12 lines in 2 locations

components/composite/controller.php 2 locations

@@ 139-147 (lines=9) @@
136
137
    public function filter($v)
138
    {
139
        foreach($this->components as $component)
140
        {
141
            if($component instanceof FilterableComponentInterface &&
142
               \is_callable($component->filter))
143
            {
144
                $n = $component->name;
145
                $v[$n] = $component->filter($v[$n]);
146
            }
147
        }
148
        
149
        return $v;
150
    }
@@ 154-165 (lines=12) @@
151
152
    public function validation($v,&$e)
153
    {
154
        foreach($this->components as $component)
155
        {
156
            if($component instanceof ValidatableComponentInterface &&
157
               \is_callable($component->validation))
158
            {
159
                $n = $component->name;
160
                if(!$component->validation($v[$n],$e))
161
                {
162
                    return false;
163
                }
164
            }
165
        }
166
        return true;
167
    }
168