Fix dynamic name (and filter!) validation accidentally applying to comments.
This commit is contained in:
@@ -86,6 +86,7 @@ class Mustache_Parser
|
||||
$this->lineTokens = 0;
|
||||
}
|
||||
|
||||
if ($token[Mustache_Tokenizer::TYPE] !== Mustache_Tokenizer::T_COMMENT) {
|
||||
if ($this->pragmaDynamicNames && isset($token[Mustache_Tokenizer::NAME])) {
|
||||
list($name, $isDynamic) = $this->getDynamicName($token);
|
||||
if ($isDynamic) {
|
||||
@@ -101,6 +102,7 @@ class Mustache_Parser
|
||||
$token[Mustache_Tokenizer::FILTERS] = $filters;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
switch ($token[Mustache_Tokenizer::TYPE]) {
|
||||
case Mustache_Tokenizer::T_DELIM_CHANGE:
|
||||
|
||||
Reference in New Issue
Block a user