More yoda conditions
This commit is contained in:
@ -33,22 +33,23 @@ class Async_Calls {
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
static $registry = [];
|
||||
public static $registry = [];
|
||||
|
||||
/**
|
||||
* Registers a new listener.
|
||||
*
|
||||
* @since 2.0.7
|
||||
*
|
||||
* @param string $id The id of the listener.
|
||||
* @param callable $callable A callback to be run.
|
||||
* @param callable $callback A callback to be run.
|
||||
* @param mixed ...$args Arguments to be passed to the callback.
|
||||
*
|
||||
* @return void
|
||||
*@since 2.0.7
|
||||
*
|
||||
*/
|
||||
public static function register_listener($id, $callable, ...$args): void {
|
||||
public static function register_listener($id, $callback, ...$args): void {
|
||||
|
||||
self::$registry[ $id ] = [
|
||||
'callable' => $callable,
|
||||
'callable' => $callback,
|
||||
'args' => $args,
|
||||
];
|
||||
}
|
||||
|
Reference in New Issue
Block a user