public function acoUpdate($params = [])
{
$root = $this->_checkNode($this->rootNode, $this->rootNode, null);
if (empty($params['plugin'])) {
$plugins = Plugin::loaded();
$this->_processControllers($root);
$this->_processPrefixes($root);
$this->_processPlugins($root, $plugins);
} else {
$plugin = $params['plugin'];
if (!Plugin::loaded($plugin)) {
$this->err(__d('cake_acl', "<error>Plugin {0} not found or not activated.</error>", [$plugin]));
return false;
}
$plugins = [$params['plugin']];
$this->_processPlugins($root, $plugins);
$this->foundACOs = array_slice($this->foundACOs, 1, null, true);
}
if ($this->_clean) {
foreach ($this->foundACOs as $parentId => $acosList) {
$this->_cleaner($parentId, $acosList);
}
}
$this->out(__d('cake_acl', '<success>Aco Update Complete</success>'));
return true;
}