| Conditions | 3 |
| Paths | 3 |
| Total Lines | 15 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 52 | private function convert($entities) { |
||
| 53 | $converted = []; |
||
| 54 | |||
| 55 | foreach($entities as $entity) { |
||
| 56 | if($entity instanceof IAPI) { |
||
| 57 | $converted[] = $entity->toAPI(); |
||
| 58 | |||
| 59 | // break if it contains anything else than entities |
||
| 60 | } else { |
||
| 61 | return $entities; |
||
| 62 | } |
||
| 63 | } |
||
| 64 | |||
| 65 | return $converted; |
||
| 66 | } |
||
| 67 | |||
| 68 | } |