protected function Twig_Node_SandboxedModule::compileDisplayFooter

Overrides Twig_Node_Module::compileDisplayFooter

File

drupal/core/vendor/twig/twig/lib/Twig/Node/SandboxedModule.php, line 43

Class

Twig_Node_SandboxedModule
Represents a module node.

Code

protected function compileDisplayFooter(Twig_Compiler $compiler) {
  parent::compileDisplayFooter($compiler);
  $compiler
    ->write("protected function checkSecurity() {\n")
    ->indent()
    ->write("\$this->env->getExtension('sandbox')->checkSecurity(\n")
    ->indent()
    ->write(!$this->usedTags ? "array(),\n" : "array('" . implode('\', \'', $this->usedTags) . "'),\n")
    ->write(!$this->usedFilters ? "array(),\n" : "array('" . implode('\', \'', $this->usedFilters) . "'),\n")
    ->write(!$this->usedFunctions ? "array()\n" : "array('" . implode('\', \'', $this->usedFunctions) . "')\n")
    ->outdent()
    ->write(");\n")
    ->outdent()
    ->write("}\n\n");
}