source/Core/Module/ModuleChainsGenerator.php
public function disableModule($modulePath)
    {
        $module = oxNew(\OxidEsales\Eshop\Core\Module\Module::class);
        $moduleId = $module->getIdByPath($modulePath);
        $module->load($moduleId);

        $moduleCache = oxNew('oxModuleCache', $module);
        $moduleInstaller = oxNew('oxModuleInstaller', $moduleCache);

        return $moduleInstaller->deactivate($module);
    }
public function disableModule($modulePath)
    {
        $module = oxNew(\OxidEsales\Eshop\Core\Module\Module::class);
        $moduleId = $module->getIdByPath($modulePath);
        $module->load($moduleId);

        $moduleCache = oxNew('oxModuleCache', $module);
        $moduleInstaller = oxNew('oxModuleInstaller', $moduleCache);

        return $moduleInstaller->deactivate($module);
    }
public function disableModule ( $ modulePath ) { $ module = oxNew ( \ OxidEsales \ Eshop \ Core \ Module \ Module :: class ) ; $ moduleId = $ module -> getIdByPath ( $ modulePath ) ; $ module -> load ( $ moduleId ) ; $ moduleCache = oxNew ( 'oxModuleCache' , $ module ) ; $ moduleInstaller = oxNew ( 'oxModuleInstaller' , $ moduleCache ) ; return $ moduleInstaller -> deactivate ( $ module ) ; }
Disables module, adds to aDisabledModules config.

@param string $modulePath Full module path

@return bool
Disables module adds to aDisabledModules config .