You are here

public function SpamspanExtension::getFilters in SpamSpan filter 8

Same name and namespace in other branches
  1. 8.2 src/TwigExtension/SpamspanExtension.php \Drupal\spamspan\TwigExtension\SpamspanExtension::getFilters()

File

src/TwigExtension/SpamspanExtension.php, line 33

Class

SpamspanExtension
Provides the SpamSpan filter function within Twig templates.

Namespace

Drupal\spamspan\TwigExtension

Code

public function getFilters() {
  return [
    new \Twig_SimpleFilter('spamspan', [
      $this,
      'spamSpanFilter',
    ], [
      'is_safe' => [
        'html',
      ],
    ]),
  ];
}