1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-05-30 11:11:23 +02:00

Merge branch '3.3.x'

This commit is contained in:
Marc Alexander 2020-03-01 18:59:48 +01:00
commit 11ee6fac28
No known key found for this signature in database
GPG Key ID: 50E0D2423696F995

View File

@ -13,11 +13,11 @@
namespace phpbb\event; namespace phpbb\event;
use Symfony\Component\EventDispatcher\ContainerAwareEventDispatcher; use Symfony\Component\EventDispatcher\EventDispatcher;
use Symfony\Component\EventDispatcher\Event; use Symfony\Component\EventDispatcher\Event;
/** /**
* Extension of the Symfony2 EventDispatcher * Extension of the Symfony EventDispatcher
* *
* It provides an additional `trigger_event` method, which * It provides an additional `trigger_event` method, which
* gives some syntactic sugar for dispatching events. Instead * gives some syntactic sugar for dispatching events. Instead
@ -30,7 +30,7 @@ use Symfony\Component\EventDispatcher\Event;
* extract($phpbb_dispatcher->trigger_event('core.index', compact($vars))); * extract($phpbb_dispatcher->trigger_event('core.index', compact($vars)));
* *
*/ */
class dispatcher extends ContainerAwareEventDispatcher implements dispatcher_interface class dispatcher extends EventDispatcher implements dispatcher_interface
{ {
/** /**
* @var bool * @var bool
@ -40,7 +40,7 @@ class dispatcher extends ContainerAwareEventDispatcher implements dispatcher_int
/** /**
* {@inheritdoc} * {@inheritdoc}
*/ */
public function trigger_event($eventName, $data = array()) public function trigger_event($eventName, $data = [])
{ {
$event = new \phpbb\event\data($data); $event = new \phpbb\event\data($data);
$this->dispatch($eventName, $event); $this->dispatch($eventName, $event);