Skip to content

Commit

Permalink
Merge pull request #80 from prilka/symfony54-deprecations
Browse files Browse the repository at this point in the history
Add return types to remove deprecation warning
  • Loading branch information
notFloran authored Mar 4, 2022
2 parents ea84d5c + 995d9ae commit ee7fb6a
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/DependencyInjection/Configuration.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

class Configuration implements ConfigurationInterface
{
public function getConfigTreeBuilder()
public function getConfigTreeBuilder(): TreeBuilder
{
$treeBuilder = new TreeBuilder('mjml');
if (\method_exists($treeBuilder, 'getRootNode')) {
Expand Down
2 changes: 1 addition & 1 deletion src/Twig/Node.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ public function __construct(Twig_Node $value, $line, $tag = null)
/**
* Compile the provided mjml into html.
*/
public function compile(Compiler $compiler)
public function compile(Compiler $compiler): void
{
$compiler->addDebugInfo($this)
->write('ob_start();'.PHP_EOL)
Expand Down
3 changes: 2 additions & 1 deletion src/Twig/TokenParser.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,13 @@

namespace NotFloran\MjmlBundle\Twig;

use Twig\Node\Node as Twig_Node;
use Twig\Token;
use Twig\TokenParser\AbstractTokenParser;

class TokenParser extends AbstractTokenParser
{
public function parse(Token $token)
public function parse(Token $token): Twig_Node
{
$line = $token->getLine();

Expand Down

0 comments on commit ee7fb6a

Please sign in to comment.