Skip to content

Commit 65bfd46

Browse files
committed
Use a safer code sample for Twig best practices
1 parent ecde568 commit 65bfd46

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

best_practices/templates.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ service in the constructor of the Twig extension:
131131
new \Twig_SimpleFilter(
132132
'md2html',
133133
array($this, 'markdownToHtml'),
134-
array('is_safe' => array('html'))
134+
array('is_safe' => array('html'), 'pre_escape' => 'html')
135135
),
136136
);
137137
}

0 commit comments

Comments
 (0)