1
0
mirror of https://github.com/flextype/flextype.git synced 2025-08-19 11:21:30 +02:00

Flextype Core: JsonParserTwigExtension renamed to JsonTwigExtension

- json_parser_decode renamed to json_decode
- json_parser_encode renamed to json_encode
This commit is contained in:
Awilum
2019-08-18 11:32:17 +03:00
parent 7d30090ea2
commit b4f0ca85ee

View File

@@ -12,7 +12,7 @@ namespace Flextype;
use Twig_Extension;
use Twig_SimpleFunction;
class JsonParserTwigExtension extends Twig_Extension
class JsonTwigExtension extends Twig_Extension
{
/**
* Returns a list of functions to add to the existing list.
@@ -22,8 +22,8 @@ class JsonParserTwigExtension extends Twig_Extension
public function getFunctions() : array
{
return [
new Twig_SimpleFunction('json_parser_decode', [$this, 'decode']),
new Twig_SimpleFunction('json_parser_encode', [$this, 'encode']),
new Twig_SimpleFunction('json_decode', [$this, 'decode']),
new Twig_SimpleFunction('json_encode', [$this, 'encode']),
];
}