protected function _addModuleFiles($aModuleFiles, $sModuleId)
    {
        $aFiles = (array) Registry::getConfig()->getConfigParam('aModuleFiles');

        $old =  isset($aFiles[$sModuleId]) ? $aFiles[$sModuleId] : null;
        if ($aModuleFiles !== null) {
            $aModuleFiles = array_change_key_case($aModuleFiles, CASE_LOWER);
        }

        if (is_array($aModuleFiles)) {
            $diff = $this->diff($old,$aModuleFiles);
            if ($diff) {
                $what = $old === null ? ' everything' : var_export($diff, true);
                $this->output->warning("$sModuleId fixing files");
                $this->output->debug(" $what");
                $aFiles[$sModuleId] = $aModuleFiles;
                $this->_saveToConfig('aModuleFiles', $aFiles);
                $this->needCacheClear = true;
            }
        } else {
            if ($old) {
                $this->output->warning("$sModuleId unregister files");
                $this->_deleteModuleFiles($sModuleId);
                $this->needCacheClear = true;
            }
        }

    }
protected function _addModuleFiles($aModuleFiles, $sModuleId)
    {
        $aFiles = (array) Registry::getConfig()->getConfigParam('aModuleFiles');

        $old =  isset($aFiles[$sModuleId]) ? $aFiles[$sModuleId] : null;
        if ($aModuleFiles !== null) {
            $aModuleFiles = array_change_key_case($aModuleFiles, CASE_LOWER);
        }

        if (is_array($aModuleFiles)) {
            $diff = $this->diff($old,$aModuleFiles);
            if ($diff) {
                $what = $old === null ? ' everything' : var_export($diff, true);
                $this->output->warning("$sModuleId fixing files");
                $this->output->debug(" $what");
                $aFiles[$sModuleId] = $aModuleFiles;
                $this->_saveToConfig('aModuleFiles', $aFiles);
                $this->needCacheClear = true;
            }
        } else {
            if ($old) {
                $this->output->warning("$sModuleId unregister files");
                $this->_deleteModuleFiles($sModuleId);
                $this->needCacheClear = true;
            }
        }

    }
protected function _addModuleFiles ( $ aModuleFiles , $ sModuleId ) { $ aFiles = ( array ) Registry :: getConfig ( ) -> getConfigParam ( 'aModuleFiles' ) ; $ old = isset ( $ aFiles [ $ sModuleId ] ) ? $ aFiles [ $ sModuleId ] : null ; if ( $ aModuleFiles !== null ) { $ aModuleFiles = array_change_key_case ( $ aModuleFiles , CASE_LOWER ) ; } if ( is_array ( $ aModuleFiles ) ) { $ diff = $ this -> diff ( $ old , $ aModuleFiles ) ; if ( $ diff ) { $ what = $ old === null ? ' everything' : var_export ( $ diff , true ) ; $ this -> output -> warning ( "$sModuleId fixing files" ) ; $ this -> output -> debug ( " $what" ) ; $ aFiles [ $ sModuleId ] = $ aModuleFiles ; $ this -> _saveToConfig ( 'aModuleFiles' , $ aFiles ) ; $ this -> needCacheClear = true ; } } else { if ( $ old ) { $ this -> output -> warning ( "$sModuleId unregister files" ) ; $ this -> _deleteModuleFiles ( $ sModuleId ) ; $ this -> needCacheClear = true ; } } }
Add module files to config for auto loader.

@param array  $aModuleFiles Module files array
@param string $sModuleId    Module id
Add module files to config for auto loader .