| Conditions | 5 | 
| Paths | 3 | 
| Total Lines | 26 | 
| Code Lines | 17 | 
| Lines | 0 | 
| Ratio | 0 % | 
| Changes | 2 | ||
| Bugs | 0 | Features | 0 | 
| 1 | <?php  | 
            ||
| 18 | function execute($image, $request)  | 
            ||
| 19 | 		{ | 
            ||
| 20 | 			$mstr = $this->fval('matrix'); | 
            ||
| 21 | 			$rows = explode(',', $mstr); | 
            ||
| 22 | |||
| 23 | $matrix = array();  | 
            ||
| 24 | foreach ($this->base_matrix as $idx => $base_row)  | 
            ||
| 25 | 			{ | 
            ||
| 26 | $build_row = array();  | 
            ||
| 27 | if (isset($rows[$idx]))  | 
            ||
| 28 | 				{ | 
            ||
| 29 | $row = trim($rows[$idx]);  | 
            ||
| 30 | 					$cols = explode(' ', $row); | 
            ||
| 31 | for ($c = 0; $c < 3; $c++)  | 
            ||
| 32 | if (isset($cols[$c]))  | 
            ||
| 33 | $build_row[] = floatval(trim($cols[$c]));  | 
            ||
| 34 | else  | 
            ||
| 35 | $build_row[] = $base_row[$c];  | 
            ||
| 36 | }  | 
            ||
| 37 | else  | 
            ||
| 38 | $build_row = $base_row;  | 
            ||
| 39 | |||
| 40 | $matrix[] = $build_row;  | 
            ||
| 41 | }  | 
            ||
| 42 | |||
| 43 | 			return $image->applyConvolution($matrix, $this->fval('div'), $this->fval('offset')); | 
            ||
| 44 | }  | 
            ||
| 46 | 
Adding explicit visibility (
private,protected, orpublic) is generally recommend to communicate to other developers how, and from where this method is intended to be used.