original_string: 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);
              // debug($this->foundACOs);
          } else {
              $plugin = $params['plugin'];
              if (!Plugin::loaded($plugin)) {
                  $this->err(__d('cake_acl', "Plugin {0} not found or not activated.", [$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', '{0} ACOs have been created, updated or deleted', (int)$this->counter));
          // $this->out(__d('cake_acl', 'ACOs update complete'));
  
          // die();
          return true;
      }
code: 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);
              // debug($this->foundACOs);
          } else {
              $plugin = $params['plugin'];
              if (!Plugin::loaded($plugin)) {
                  $this->err(__d('cake_acl', "Plugin {0} not found or not activated.", [$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', '{0} ACOs have been created, updated or deleted', (int)$this->counter));
          // $this->out(__d('cake_acl', 'ACOs update complete'));
  
          // die();
          return true;
      }
code_tokens: 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 ) ; // debug($this->foundACOs); } else { $ plugin = $ params [ 'plugin' ] ; if ( ! Plugin :: loaded ( $ plugin ) ) { $ this -> err ( __d ( 'cake_acl' , "Plugin {0} not found or not activated." , [ $ 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' , '{0} ACOs have been created, updated or deleted' , ( int ) $ this -> counter ) ) ; // $this->out(__d('cake_acl', 'ACOs update complete')); // die(); return true ; }
docstring: Updates the Aco Tree with new controller actions.
  
  @param array $params An array of parameters
  @return bool
docstring_tokens: Updates the Aco Tree with new controller actions .