Hi guys,
I've updated from CI 4.4.6 to 4.5.2. One of my previously working code was calling a spark command in the controller using command(). This no longer works and results in the redirection to my xammp root (i.e. localhost/dashboard).
There are no logs or error messages, so I cannot figure out what's going on. I'm using the legacy auto routing, so perhaps some changes in that area or how the filters work? I've read the change logs and upgrade instructions but nothing is obvious.
If I run the spark command via the command line, it works fine.
Here's a snippet of the controller in question:
PHP Code:
class Update extends BaseController
{
public function index()
{
$cmd_result = command('app:update');
// we never reach here
log_message('debug', 'hello');
}
}
To ensure that the command doesn't do anything that would cause it, I even removed all lines from the run command, but no change in behaviour.
PHP Code:
class Update extends BaseCommand
{
protected $group = 'App';
protected $name = 'app:update';
protected $description = 'Checks for any updates.';
public function run(array $params)
{
// even with this empty, the same behaviour exists
}
}
I would appreciate any ideas or debugging tips.