mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 03:18:26 +00:00
Uncountable null convert to array(), revert ControllerTask::bake() signature for backward compatibility.
This commit is contained in:
parent
88c015f6d3
commit
d3d0501414
1 changed files with 7 additions and 1 deletions
|
@ -328,9 +328,15 @@ class ControllerTask extends BakeTask {
|
|||
* @param array $components Components to use in controller
|
||||
* @return string Baked controller
|
||||
*/
|
||||
public function bake($controllerName, $actions = '', $helpers = array(), $components = array()) {
|
||||
public function bake($controllerName, $actions = '', $helpers = null, $components = null) {
|
||||
$this->out("\n" . __d('cake_console', 'Baking controller class for %s...', $controllerName), 1, Shell::QUIET);
|
||||
|
||||
if (is_null($helpers)) {
|
||||
$helpers = array();
|
||||
}
|
||||
if (is_null($components)) {
|
||||
$components = array();
|
||||
}
|
||||
$isScaffold = ($actions === 'scaffold') ? true : false;
|
||||
|
||||
$this->Template->set(array(
|
||||
|
|
Loading…
Reference in a new issue