| Conditions | 2 |
| Paths | 2 |
| Total Lines | 15 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 8 |
| CRAP Score | 2 |
| Changes | 0 | ||
| 1 | <?php defined('SYSPATH') OR die('No direct script access.'); |
||
| 25 | 1 | public function group_shipping_items() |
|
| 26 | { |
||
| 27 | 1 | $group_shipping_items = array(); |
|
| 28 | |||
| 29 | 1 | foreach ($this->shipping_methods as $shipping_method) |
|
| 30 | { |
||
| 31 | 1 | $group_shipping_items []= new Group_Shipping_Items( |
|
| 32 | 1 | $this->brand_purchase_shipping, |
|
| 33 | 1 | $this->purchase_items, |
|
| 34 | 1 | $shipping_method |
|
| 35 | ); |
||
| 36 | } |
||
| 37 | |||
| 38 | 1 | return $group_shipping_items; |
|
| 39 | } |
||
| 40 | } |
||
| 41 |
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.