Commit 994e5662 authored by Eloy Lafuente's avatar Eloy Lafuente
Browse files

MDL-43040 Note the deprecation and add some TODOs

parent 672ce966
......@@ -162,6 +162,7 @@ class core_plugin_manager {
$this->installedplugins = array();
// TODO: Delete this block once Moodle 2.6 or later becomes minimum required version to upgrade.
if ($CFG->version < 2013092001.02) {
// We did not upgrade the database yet.
$modules = $DB->get_records('modules', array(), 'name ASC', 'id, name, version');
......
......@@ -6,6 +6,7 @@ information provided here is intended especially for developers.
* $core_renderer->block_move_target() changed to support more verbose move-block-here descriptions.
DEPRECATIONS:
* $module uses in mod/xxx/version.php files is now deprecated. Please use $plugin instead. It will be removed in Moodle 2.10.
* Update init methods in all event classes - "level" property was renamed to "edulevel", the level property is now deprecated.
* Abstract class \core\event\course_module_instances_list_viewed is deprecated now, use \core\event\instances_list_viewed instead.
* mod_book\event\instances_list_viewed has been deprecated. Please use mod_book\event\course_module_instance_list_viewed instead.
......
......@@ -565,10 +565,11 @@ function upgrade_plugins_modules($startcallback, $endcallback, $verbose) {
throw new plugin_defective_exception($component, 'Missing version.php');
}
// TODO: Support for $module will end with Moodle 2.10 by MDL-43896. Was deprecated for Moodle 2.7 by MDL-43040.
$plugin = new stdClass();
$plugin->version = null;
$module = $plugin;
require($fullmod .'/version.php'); // Defines $module/$plugin with version etc.
require($fullmod .'/version.php'); // Defines $plugin with version etc.
$plugin = clone($module);
unset($module->version);
unset($module->component);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment