Now, my extension has a main-listener. The __construct look like this:
Code: Select all
/**
* Constructor
*
* @param \phpbb\controller\helper $helper Controller helper object
* @param \phpbb\template $template Template object
* @param \phpbb\user $user User object
* @param \phpbb\config $conmfig Config object
*/
public function __construct(\phpbb\controller\helper $helper, \phpbb\template\template $template, \phpbb\user $user, \phpbb\config\config $config)
{
$this->helper = $helper;
$this->template = $template;
$this->user = $user;
$this->config = $config;
}
and i am really clueless as to why the config object can't be included. Now, using global $config; works flawlessly so i can get around the problem but i am stuck in understanding the resaon of this error. Anyone has an explanation?Catchable fatal error: Argument 4 passed to infopolitie\header_extension\event\main_listener::__construct() must be an instance of phpbb\config\config, none given in C:\wamp\www\phpbb-prep-release-3.1.0-a2\phpBB\ext\infopolitie\header_extension\event\main_listener.php on line 50
Thnx!