Call to a member function on null error CodeIgniter
问题 Please dont`t ask why I have more than one controller: this is what my teacher wants. I have 3 controllers: Api.php , Token.php and Apikey.php , where Api.php is the "main" one. PROBLEM : When I pass into the URL : http://localhost/revolution/index.php/api/registerUser/first_name/12First it seems there are problems with loading the Token controller from Api controller. ERROR: Fatal error: Call to a member function generateToken() on null What can I do? API Controller: Api.php class api