Skip to content

Commit

Permalink
Merge pull request #24055 from eileenmcnaughton/nfc
Browse files Browse the repository at this point in the history
(NFC) HookStyleListener - Comments
  • Loading branch information
totten authored Jul 26, 2022
2 parents be5f0b4 + 18b53a1 commit a2b6254
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Civi/Core/CiviEventDispatcher.php
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ public function addSubscriberServiceMap(string $subscriber, array $events) {
* Ex: 'hook_civicrm_publicEvent'
* Ex: '&hook_civicrm_publicEvent' (an alias for 'hook_civicrm_publicEvent' in which the listener abides hook-style ordered parameters).
* This notation is handy when attaching via listener-maps (e.g. `getSubscribedEvents()`).
* @param callable $listener
* @param callable|HookStyleListener $listener
* @param int $priority
*/
public function addListener($eventName, $listener, $priority = 0) {
Expand Down
2 changes: 1 addition & 1 deletion Civi/Core/Event/HookStyleListener.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ class HookStyleListener {
private $callback = NULL;

/**
* @param array $callback
* @param array|callable $callback
* Ex: ['SomeClass', 'someMethod']
*/
public function __construct($callback) {
Expand Down

0 comments on commit a2b6254

Please sign in to comment.