Skip to content

Commit

Permalink
Merge pull request #49 from MaximePinot/master
Browse files Browse the repository at this point in the history
  • Loading branch information
rvanlaak authored Jun 9, 2020
2 parents e331dcc + c27935d commit ec4237c
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 7 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
/vendor/
composer.lock
6 changes: 3 additions & 3 deletions EventListener/BreadcrumbListener.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@
namespace APY\BreadcrumbTrailBundle\EventListener;

use Doctrine\Common\Annotations\Reader;
use Symfony\Component\HttpKernel\Event\FilterControllerEvent;
use APY\BreadcrumbTrailBundle\BreadcrumbTrail\Trail;
use APY\BreadcrumbTrailBundle\Annotation\Breadcrumb;
use Symfony\Component\HttpKernel\Event\KernelEvent;
use Symfony\Component\HttpKernel\HttpKernelInterface;

class BreadcrumbListener
Expand Down Expand Up @@ -43,9 +43,9 @@ public function __construct(Reader $reader, Trail $breadcrumbTrail)
}

/**
* @param FilterControllerEvent $event A FilterControllerEvent instance
* @param \Symfony\Component\HttpKernel\Event\FilterControllerEvent|\Symfony\Component\HttpKernel\Event\ControllerEvent $event
*/
public function onKernelController(FilterControllerEvent $event)
public function onKernelController(KernelEvent $event)
{
if (!is_array($controller = $event->getController())) {
return;
Expand Down
3 changes: 2 additions & 1 deletion Twig/BreadcrumbTrailExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
use APY\BreadcrumbTrailBundle\BreadcrumbTrail\Trail;
use Twig\Environment;
use Twig\Extension\AbstractExtension;
use Twig\TwigFunction;

/**
* Provides an extension for Twig to output breadcrumbs
Expand Down Expand Up @@ -43,7 +44,7 @@ public function __construct(Trail $trail, Environment $templating)
public function getFunctions()
{
return array(
new \Twig_SimpleFunction("apy_breadcrumb_trail_render", array($this, "renderBreadcrumbTrail"), array("is_safe" => array("html"))),
new TwigFunction("apy_breadcrumb_trail_render", array($this, "renderBreadcrumbTrail"), array("is_safe" => array("html"))),
);
}

Expand Down
6 changes: 3 additions & 3 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@
],
"require": {
"php": ">=5.3.3",
"symfony/framework-bundle": "^2.3|^3.0|^4.0",
"twig/twig": "^1.41|^2.0"
"symfony/framework-bundle": "^2.3|^3.0|^4.0|^5.0",
"twig/twig": "^1.41|^2.0|^3.0"
},
"suggest": {
"ext-intl": "*"
},
"autoload": {
"psr-0": { "APY\\BreadcrumbTrailBundle": "" }
"psr-4": { "APY\\BreadcrumbTrailBundle\\": "" }
},
"target-dir": "APY/BreadcrumbTrailBundle"
}

0 comments on commit ec4237c

Please sign in to comment.