Skip to content

Commit

Permalink
[FIX] Deprecated Twig functions usage
Browse files Browse the repository at this point in the history
  • Loading branch information
Th3Mouk committed Oct 8, 2015
1 parent ae7b408 commit 3c5c083
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
10 changes: 9 additions & 1 deletion Twig/Extension/TextFormatterExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,16 @@
*/
class TextFormatterExtension extends \Twig_Extension
{
/**
* @var Pool
*/
protected $pool;

/**
* @var \Twig_Environment
*/
protected $environment;

public function __construct(Pool $pool)
{
$this->pool = $pool;
Expand Down Expand Up @@ -50,7 +58,7 @@ public function getTokenParsers()
public function getFilters()
{
return array(
'format_text' => new \Twig_Filter_Method($this, 'transform'),
'format_text' => new \Twig_SimpleFilter($this, 'transform'),
);
}

Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"symfony/framework-bundle": "~2.3",
"symfony/form": "~2.3",
"symfony/property-access": "~2.3",
"twig/twig": "*",
"twig/twig": "~1.12",
"knplabs/knp-markdown-bundle": "~1.3.2",
"egeloen/ckeditor-bundle": "~2.2",
"sonata-project/block-bundle": "~2.2,>=2.2.1",
Expand Down

0 comments on commit 3c5c083

Please sign in to comment.