| Conditions | 2 |
| Paths | 2 |
| Total Lines | 7 |
| Code Lines | 4 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 22 | public static function buildIndexActionArray(&$metaDataArray, $section) |
||
| 23 | { |
||
| 24 | $loader = GeneralUtility::makeInstance(\HDNET\OnpageIntegration\Loader\ApiResultLoader::class); |
||
| 25 | for ($i = 0; $i < count($metaDataArray[0]); $i++) { |
||
|
|
|||
| 26 | $metaDataArray[0][$i]['errors'] = $loader->load('zoom_' . $section . '_' . $i . '_graph'); |
||
| 27 | } |
||
| 28 | } |
||
| 29 | } |
||
| 30 |
If the size of the collection does not change during the iteration, it is generally a good practice to compute it beforehand, and not on each iteration: