Removed anonymous function and reference to Twig (not used anymore)