Skip to content

Commit

Permalink
minor #222 Don't make Twig filters safe for HTML by default (javiereg…
Browse files Browse the repository at this point in the history
…uiluz)

This PR was merged into the 1.0-dev branch.

Discussion
----------

Don't make Twig filters safe for HTML by default

This fixes #200.

I disagree with this change ... but I guess most people will agree with it ... so let's do it.

Commits
-------

3b48d7a Don't make Twig filters safe for HTML by default
  • Loading branch information
javiereguiluz committed Jul 6, 2018
2 parents 432caaa + 3b48d7a commit dfe6661
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Resources/skeleton/twig/Extension.tpl.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ class <?= $class_name ?> extends AbstractExtension
public function getFilters(): array
{
return [
new TwigFilter('filter_name', [$this, 'doSomething'], ['is_safe' => ['html']]),
new TwigFilter('filter_name', [$this, 'doSomething']),
];
}

Expand Down

0 comments on commit dfe6661

Please sign in to comment.