Skip to content

Commit

Permalink
[FIX] Check if method exists in update.php script
Browse files Browse the repository at this point in the history
Fix so we could use update.php with the previous version of system
where this method was not present
  • Loading branch information
bukowskiadam committed Jan 11, 2017
1 parent c88c5af commit 4ffc653
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion update.php
Original file line number Diff line number Diff line change
Expand Up @@ -340,7 +340,14 @@ protected function load_epesi()
define('CID', false);
require_once 'include.php';
require_once 'include/backups.php';
ModuleManager::enable_modules(ModuleManager::MODULE_NOT_FOUND);

// Enable all disabled modules
// check if method exists, because we recommend to use this update
// script on older installations where method was not present
if (method_exists('ModuleManager', 'enable_modules')) {
ModuleManager::enable_modules(ModuleManager::MODULE_NOT_FOUND);
}

ModuleManager::load_modules();
Base_LangCommon::load();

Expand Down

0 comments on commit 4ffc653

Please sign in to comment.