Fix for iterator arguments
This commit is contained in:
parent
f54dded1e0
commit
e8ea04f323
1 changed files with 3 additions and 0 deletions
|
@ -57,6 +57,9 @@ class ProgressViewHelper extends AbstractViewHelper
|
|||
//handling famous off by one
|
||||
$activeStep -= $offset;
|
||||
//make sure our array index is numeric
|
||||
if (\is_iterable($links)) {
|
||||
$links = \iterator_to_array($links);
|
||||
}
|
||||
$links = \array_values($links);
|
||||
if (!$linkCount) {
|
||||
$linkCount = \count($links);
|
||||
|
|
Loading…
Reference in a new issue