Open vetaltor opened 5 years ago
Also, foreach ($lines as $n => $line)
is not equal to while (list($n, $line) = each($lines))
(from original file https://github.com/zendframework/zf1/blob/136735e776f520b081cd374012852cb88cef9a88/library/Zend/Config/Yaml.php#L292). Since it does reset()
, and also in PHP7 foreach
loop doesn't utilize array pointer.
Yaml parsing is very slow as well. It would be better to use any other Yaml parser than the ZF1 yaml parser.
Exception #0 (Exception): Notice: Undefined variable: line in ../vendor/magento/zendframework1/library/Zend/Config/Yaml.php on line 292
https://github.com/magento/zf1/blob/4df018254c70b5b998b00a8cb1a30760f831ff0d/library/Zend/Config/Yaml.php#L292