Skip to content

Commit

Permalink
try updated signature
Browse files Browse the repository at this point in the history
  • Loading branch information
demeritcowboy committed Aug 10, 2022
1 parent a48094d commit 5220624
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions Civi/Core/DaveEventDispatcher.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,7 @@

class DaveEventDispatcher extends \Symfony\Component\EventDispatcher\EventDispatcher {

public function dispatch($event/*, string $eventName = null*/) {
$eventName = 1 < \func_num_args() ? func_get_arg(1) : NULL;

public function dispatch(object $event, ?string $eventName = null): object {
$eventName = $eventName ?? \get_class($event);
$listeners = $this->getListeners($eventName);

Expand Down

0 comments on commit 5220624

Please sign in to comment.