mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 11:28:25 +00:00
Changing new Model() for ClassRegistry::init(). Fixes issues when baking admin and non-admin methods for a controller that uses bound translations + TranslateBehavior. Fixes #245
This commit is contained in:
parent
a7a6dc8c43
commit
38f578199d
1 changed files with 1 additions and 1 deletions
|
@ -252,7 +252,7 @@ class ControllerTask extends Shell {
|
||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
$actions = null;
|
$actions = null;
|
||||||
$modelObj =& new $currentModelName();
|
$modelObj =& ClassRegistry::init($currentModelName);
|
||||||
$controllerPath = $this->_controllerPath($controllerName);
|
$controllerPath = $this->_controllerPath($controllerName);
|
||||||
$pluralName = $this->_pluralName($currentModelName);
|
$pluralName = $this->_pluralName($currentModelName);
|
||||||
$singularName = Inflector::variable($currentModelName);
|
$singularName = Inflector::variable($currentModelName);
|
||||||
|
|
Loading…
Reference in a new issue