You are here

public function TwigTransTokenParser::decideForFork in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/lib/Drupal/Core/Template/TwigTransTokenParser.php \Drupal\Core\Template\TwigTransTokenParser::decideForFork()

Detect a 'plural' switch or the end of a 'trans' tag.

File

core/lib/Drupal/Core/Template/TwigTransTokenParser.php, line 64
Contains \Drupal\Core\Template\TwigTransTokenParser.

Class

TwigTransTokenParser
A class that defines the Twig 'trans' token parser for Drupal.

Namespace

Drupal\Core\Template

Code

public function decideForFork($token) {
  return $token
    ->test(array(
    'plural',
    'endtrans',
  ));
}