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
|
//handling famous off by one
|
||||||
$activeStep -= $offset;
|
$activeStep -= $offset;
|
||||||
//make sure our array index is numeric
|
//make sure our array index is numeric
|
||||||
|
if (\is_iterable($links)) {
|
||||||
|
$links = \iterator_to_array($links);
|
||||||
|
}
|
||||||
$links = \array_values($links);
|
$links = \array_values($links);
|
||||||
if (!$linkCount) {
|
if (!$linkCount) {
|
||||||
$linkCount = \count($links);
|
$linkCount = \count($links);
|
||||||
|
|
Loading…
Reference in a new issue