mirror of
https://github.com/twigphp/Twig.git
synced 2026-09-16 12:26:30 +00:00
prepared the 1.23.1 release
This commit is contained in:
+1
-1
@@ -15,7 +15,7 @@
|
||||
#ifndef PHP_TWIG_H
|
||||
#define PHP_TWIG_H
|
||||
|
||||
#define PHP_TWIG_VERSION "1.23.1-DEV"
|
||||
#define PHP_TWIG_VERSION "1.23.1"
|
||||
|
||||
#include "php.h"
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
*/
|
||||
class Twig_Environment
|
||||
{
|
||||
const VERSION = '1.23.1-DEV';
|
||||
const VERSION = '1.23.1';
|
||||
|
||||
protected $charset;
|
||||
protected $loader;
|
||||
@@ -961,11 +961,13 @@ class Twig_Environment
|
||||
foreach ($this->filters as $pattern => $filter) {
|
||||
$pattern = str_replace('\\*', '(.*?)', preg_quote($pattern, '#'), $count);
|
||||
|
||||
if ($count && preg_match('#^'.$pattern.'$#', $name, $matches)) {
|
||||
array_shift($matches);
|
||||
$filter->setArguments($matches);
|
||||
if ($count) {
|
||||
if (preg_match('#^'.$pattern.'$#', $name, $matches)) {
|
||||
array_shift($matches);
|
||||
$filter->setArguments($matches);
|
||||
|
||||
return $filter;
|
||||
return $filter;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1110,11 +1112,13 @@ class Twig_Environment
|
||||
foreach ($this->functions as $pattern => $function) {
|
||||
$pattern = str_replace('\\*', '(.*?)', preg_quote($pattern, '#'), $count);
|
||||
|
||||
if ($count && preg_match('#^'.$pattern.'$#', $name, $matches)) {
|
||||
array_shift($matches);
|
||||
$function->setArguments($matches);
|
||||
if ($count) {
|
||||
if (preg_match('#^'.$pattern.'$#', $name, $matches)) {
|
||||
array_shift($matches);
|
||||
$function->setArguments($matches);
|
||||
|
||||
return $function;
|
||||
return $function;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user