mirror of
https://github.com/twigphp/Twig.git
synced 2026-09-12 02:16:41 +00:00
25cc3e418ac2569a4888af0c452bbccf37b480c2
This PR was squashed before being merged into the 2.x branch (closes #3046).
Discussion
----------
Fixed: Endless loop if more than one parent without the macro exists
Hi @fabpot
I made a quick fix for the parent macro method call fix you did for me in #3042. Your code works in case the direct parent has the macro. But if there is a longer hierarchy and the looked for macro is in a parent template +1 it runs into an endless loop because the `->getParent()` method is always called on `$template` but never the newer `$parent`.
Best
Commits
-------
44970833 Fixed: Endless loop if more than one parent without the macro exists
Twig, the flexible, fast, and secure template language for PHP ============================================================== Twig is a template language for PHP, released under the new BSD license (code and documentation). Twig uses a syntax similar to the Django and Jinja template languages which inspired the Twig runtime environment. More Information ---------------- Read the `documentation`_ for more information. .. _documentation: https://twig.symfony.com/documentation
Description
Languages
PHP
99.9%