src/Events/EventEmitter.php
/**
	 * Binds the callback function to be executed each time the channel is invoked.
	 *
	 * @param string $channel Event channel.
	 * @param callable $callback Callback function.
	 */
Binds the callback function to be executed each time the channel is invoked.
@param string $channel Event channel.
@param callable $callback Callback function.
Binds the callback function to be executed each time the channel is invoked . @param string $channel Event channel . @param callable $callback Callback function .
public function on($channel, callable $callback) {
		$this->prepare($channel);
		$this->hooks[$channel][] = new EventCallback($callback, EVENT_EVERY);
	}
public function on ( $ channel , callable $ callback ) { $ this -> prepare ( $ channel ) ; $ this -> hooks [ $ channel ] [ ] = new EventCallback ( $ callback , EVENT_EVERY ) ; }
Binds the callback function to be executed each time the channel is invoked.
Binds the callback function to be executed each time the channel is invoked .
// Create an array for the channel if needed // Add the callback to the channel