Fix for using {{render}} with same template multiple times, which caused an assertion error