MDL-32329 improved plugin dependencies check on upgrade
Previously, it was the renderer method that actually called all_plugins_ok(). I believe that renderer methods should not be responsible for such an important step in the install/upgrade code flow. So dependencies are now checked by admin/index.php on upgrade, too.
This commit is contained in:
+7
-11
@@ -219,19 +219,15 @@ class core_admin_renderer extends plugin_renderer_base {
|
||||
$output .= $this->box_end();
|
||||
$output .= $this->upgrade_reload($reloadurl);
|
||||
|
||||
if ($pluginman->all_plugins_ok($version)) {
|
||||
if ($pluginman->some_plugins_updatable()) {
|
||||
$output .= $this->container_start('upgradepluginsinfo');
|
||||
$output .= $this->help_icon('upgradepluginsinfo', 'core_admin', get_string('upgradepluginsfirst', 'core_admin'));
|
||||
$output .= $this->container_end();
|
||||
}
|
||||
$button = new single_button($continueurl, get_string('upgradestart', 'admin'), 'get');
|
||||
$button->class = 'continuebutton';
|
||||
$output .= $this->render($button);
|
||||
} else {
|
||||
$output .= $this->box(get_string('pluginschecktodo', 'admin'), 'environmentbox errorbox');
|
||||
if ($pluginman->some_plugins_updatable()) {
|
||||
$output .= $this->container_start('upgradepluginsinfo');
|
||||
$output .= $this->help_icon('upgradepluginsinfo', 'core_admin', get_string('upgradepluginsfirst', 'core_admin'));
|
||||
$output .= $this->container_end();
|
||||
}
|
||||
|
||||
$button = new single_button($continueurl, get_string('upgradestart', 'admin'), 'get');
|
||||
$button->class = 'continuebutton';
|
||||
$output .= $this->render($button);
|
||||
$output .= $this->footer();
|
||||
|
||||
return $output;
|
||||
|
||||
Reference in New Issue
Block a user