From f37f00be538fd4c14dad92b3ae3f9ebc028dad6f Mon Sep 17 00:00:00 2001 From: "Eloy Lafuente (stronk7)" Date: Sun, 30 Dec 2018 18:05:30 +0100 Subject: [PATCH 1/5] MDL-63276 environment: 3.7 base information This is a direct copy of the 3.6 branch to have changes under control easier in next commits. --- admin/environment.xml | 181 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 181 insertions(+) diff --git a/admin/environment.xml b/admin/environment.xml index 40e66be21ff18..5cebc43aa9b2f 100644 --- a/admin/environment.xml +++ b/admin/environment.xml @@ -2618,4 +2618,185 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From 504d1a9cc072660e35b999e04ca17e9c73695ec0 Mon Sep 17 00:00:00 2001 From: "Eloy Lafuente (stronk7)" Date: Sun, 30 Dec 2018 18:08:35 +0100 Subject: [PATCH 2/5] MDL-63276 environment: PHP 7.1 and Moodle 3.2 required --- admin/environment.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/admin/environment.xml b/admin/environment.xml index 5cebc43aa9b2f..ca20d0c68156b 100644 --- a/admin/environment.xml +++ b/admin/environment.xml @@ -2618,7 +2618,7 @@ - + @@ -2631,7 +2631,7 @@ - + From 422947e0705c4dad00cca590d93f72c698fa1caa Mon Sep 17 00:00:00 2001 From: "Eloy Lafuente (stronk7)" Date: Thu, 3 Jan 2019 01:14:44 +0100 Subject: [PATCH 3/5] MDL-63276 install: PHP min version checker bump to PHP 7.1 --- lib/phpminimumversionlib.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/phpminimumversionlib.php b/lib/phpminimumversionlib.php index 7beeac0e39308..0c3e0d179cc3a 100644 --- a/lib/phpminimumversionlib.php +++ b/lib/phpminimumversionlib.php @@ -48,8 +48,8 @@ function moodle_minimum_php_version_is_met($haltexecution = false) { // PLEASE NOTE THIS FUNCTION MUST BE COMPATIBLE WITH OLD UNSUPPORTED VERSIONS OF PHP. // Do not use modern php features or Moodle convenience functions (e.g. localised strings). - $minimumversion = '7.0.0'; - $moodlerequirementchanged = '3.4'; + $minimumversion = '7.1.0'; + $moodlerequirementchanged = '3.7'; if (version_compare(PHP_VERSION, $minimumversion) < 0) { if ($haltexecution) { From f580d20adfb173f2047be755a36998b0f9e69414 Mon Sep 17 00:00:00 2001 From: "Eloy Lafuente (stronk7)" Date: Wed, 2 Jan 2019 11:19:15 +0100 Subject: [PATCH 4/5] MDL-63276 travis support: Bump to PHP 7.1 required --- .travis.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index aa0db16fa9ab4..ec1b68cb906fe 100644 --- a/.travis.yml +++ b/.travis.yml @@ -14,7 +14,7 @@ language: php php: # We only run the highest and lowest supported versions to reduce the load on travis-ci.org. - 7.2 - - 7.0 + - 7.1 addons: postgresql: "9.6" @@ -63,7 +63,7 @@ matrix: # Exclude it on all versions except for 7.2 - env: DB=mysqli TASK=PHPUNIT - php: 7.0 + php: 7.1 cache: directories: From a12207be259bbd55bc6c7fd02ff8ea94f9b71e36 Mon Sep 17 00:00:00 2001 From: "Eloy Lafuente (stronk7)" Date: Sun, 30 Dec 2018 19:39:56 +0100 Subject: [PATCH 5/5] MDL-63276 upgrade: clean < 3.2.0 upgrade steps 3.7 (min PHP 7.1) requires 3.2 (first version supporting PHP 7.1) This just deletes all the upgrade steps previous to 3.2.0. Some small adjustments, like adding missing MOODLE_INTERNAL or tweaking globals can also be applied when needed. Also includes an upgrade step to prevent upgrading from any version < 2016120500 (v3.2.0) as anti-cheating measure. Next commit will get rid of/deprecate all the upgradelib functions not used anymore in codebase. (note there isn't any this time). --- admin/tool/customlang/db/upgrade.php | 3 - admin/tool/log/db/upgrade.php | 3 - admin/tool/log/store/database/db/upgrade.php | 3 - admin/tool/log/store/standard/db/upgrade.php | 3 - admin/tool/monitor/db/upgrade.php | 20 - admin/tool/usertours/db/upgrade.php | 3 - auth/cas/db/upgrade.php | 3 - auth/db/db/upgrade.php | 3 - auth/email/db/upgrade.php | 3 - auth/ldap/db/upgrade.php | 3 - auth/manual/db/upgrade.php | 3 - auth/mnet/db/upgrade.php | 2 - auth/none/db/upgrade.php | 3 - auth/oauth2/db/upgrade.php | 3 - auth/shibboleth/db/upgrade.php | 3 - blocks/badges/db/upgrade.php | 3 - blocks/calendar_month/db/upgrade.php | 3 - blocks/calendar_upcoming/db/upgrade.php | 3 - blocks/community/db/upgrade.php | 3 - blocks/completionstatus/db/upgrade.php | 3 - blocks/course_summary/db/upgrade.php | 3 - blocks/html/db/upgrade.php | 3 - blocks/navigation/db/upgrade.php | 3 - blocks/quiz_results/db/upgrade.php | 3 - blocks/recent_activity/db/upgrade.php | 3 - blocks/rss_client/db/upgrade.php | 3 - blocks/section_links/db/upgrade.php | 3 - blocks/selfcompletion/db/upgrade.php | 3 - blocks/settings/db/upgrade.php | 3 - enrol/database/db/upgrade.php | 3 - enrol/flatfile/db/upgrade.php | 3 - enrol/guest/db/upgrade.php | 3 - enrol/imsenterprise/db/upgrade.php | 3 - enrol/lti/db/upgrade.php | 204 ---------- enrol/manual/db/upgrade.php | 3 - enrol/mnet/db/upgrade.php | 3 - enrol/paypal/db/upgrade.php | 3 - enrol/self/db/upgrade.php | 20 +- filter/mathjaxloader/db/upgrade.php | 29 -- filter/mediaplugin/db/upgrade.php | 3 - filter/tex/db/upgrade.php | 3 - grade/grading/form/guide/db/upgrade.php | 3 - grade/grading/form/rubric/db/upgrade.php | 3 - grade/report/user/db/upgrade.php | 3 - lib/antivirus/clamav/db/upgrade.php | 19 - lib/db/upgrade.php | 381 +----------------- lib/editor/atto/db/upgrade.php | 3 - .../atto/plugins/equation/db/upgrade.php | 3 - lib/editor/tinymce/db/upgrade.php | 3 - .../plugins/spellchecker/db/upgrade.php | 3 - message/output/email/db/upgrade.php | 3 - message/output/jabber/db/upgrade.php | 3 - message/output/popup/db/upgrade.php | 28 -- mod/assign/db/upgrade.php | 34 +- mod/assign/feedback/comments/db/upgrade.php | 3 - mod/assign/feedback/editpdf/db/upgrade.php | 3 - mod/assign/feedback/file/db/upgrade.php | 3 - mod/assign/submission/comments/db/upgrade.php | 3 - mod/assign/submission/file/db/upgrade.php | 3 - .../submission/onlinetext/db/upgrade.php | 3 - mod/assignment/db/upgrade.php | 3 - mod/book/db/upgrade.php | 3 - mod/chat/db/upgrade.php | 3 - mod/choice/db/upgrade.php | 3 - mod/data/db/upgrade.php | 18 - mod/feedback/db/upgrade.php | 3 - mod/folder/db/upgrade.php | 3 - mod/forum/db/upgrade.php | 18 - mod/glossary/db/upgrade.php | 3 - mod/imscp/db/upgrade.php | 3 - mod/label/db/upgrade.php | 3 - mod/lesson/db/upgrade.php | 3 - mod/lti/db/upgrade.php | 18 - mod/page/db/upgrade.php | 3 - mod/quiz/db/upgrade.php | 55 --- mod/quiz/report/overview/db/upgrade.php | 3 - mod/quiz/report/statistics/db/upgrade.php | 10 - mod/resource/db/upgrade.php | 3 - mod/scorm/db/upgrade.php | 15 - mod/survey/db/upgrade.php | 22 +- mod/url/db/upgrade.php | 3 - mod/wiki/db/upgrade.php | 3 - mod/workshop/db/upgrade.php | 3 - mod/workshop/form/accumulative/db/upgrade.php | 3 - mod/workshop/form/comments/db/upgrade.php | 3 - mod/workshop/form/numerrors/db/upgrade.php | 3 - mod/workshop/form/rubric/db/upgrade.php | 3 - portfolio/boxnet/db/upgrade.php | 3 - portfolio/googledocs/db/upgrade.php | 3 - portfolio/picasa/db/upgrade.php | 3 - .../behaviour/manualgraded/db/upgrade.php | 3 - question/type/calculated/db/upgrade.php | 3 - question/type/ddmarker/db/upgrade.php | 3 - question/type/essay/db/upgrade.php | 3 - question/type/match/db/upgrade.php | 3 - question/type/multianswer/db/upgrade.php | 3 - question/type/multichoice/db/upgrade.php | 3 - question/type/numerical/db/upgrade.php | 15 +- question/type/random/db/upgrade.php | 3 - question/type/randomsamatch/db/upgrade.php | 3 - question/type/shortanswer/db/upgrade.php | 3 - repository/boxnet/db/upgrade.php | 3 - repository/dropbox/db/upgrade.php | 7 - repository/googledocs/db/upgrade.php | 3 - repository/picasa/db/upgrade.php | 3 - theme/more/db/upgrade.php | 3 - 106 files changed, 13 insertions(+), 1166 deletions(-) diff --git a/admin/tool/customlang/db/upgrade.php b/admin/tool/customlang/db/upgrade.php index 584931143faba..53fa80a2039d9 100644 --- a/admin/tool/customlang/db/upgrade.php +++ b/admin/tool/customlang/db/upgrade.php @@ -29,9 +29,6 @@ function xmldb_tool_customlang_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/admin/tool/log/db/upgrade.php b/admin/tool/log/db/upgrade.php index 70a76cc67b5a2..bbf196143f9a0 100644 --- a/admin/tool/log/db/upgrade.php +++ b/admin/tool/log/db/upgrade.php @@ -33,9 +33,6 @@ function xmldb_tool_log_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/admin/tool/log/store/database/db/upgrade.php b/admin/tool/log/store/database/db/upgrade.php index 0804ce826a5b1..04137ab420f10 100644 --- a/admin/tool/log/store/database/db/upgrade.php +++ b/admin/tool/log/store/database/db/upgrade.php @@ -27,9 +27,6 @@ function xmldb_logstore_database_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/admin/tool/log/store/standard/db/upgrade.php b/admin/tool/log/store/standard/db/upgrade.php index 14946e8ee20d0..d6cd26d42327f 100644 --- a/admin/tool/log/store/standard/db/upgrade.php +++ b/admin/tool/log/store/standard/db/upgrade.php @@ -27,9 +27,6 @@ function xmldb_logstore_standard_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/admin/tool/monitor/db/upgrade.php b/admin/tool/monitor/db/upgrade.php index ee22b83e9528a..f8579c9183ae0 100644 --- a/admin/tool/monitor/db/upgrade.php +++ b/admin/tool/monitor/db/upgrade.php @@ -33,26 +33,6 @@ function xmldb_tool_monitor_upgrade($oldversion) { global $CFG, $DB; - $dbman = $DB->get_manager(); - - if ($oldversion < 2016052305) { - - // Define field inactivedate to be added to tool_monitor_subscriptions. - $table = new xmldb_table('tool_monitor_subscriptions'); - $field = new xmldb_field('inactivedate', XMLDB_TYPE_INTEGER, '10', null, true, null, 0, 'lastnotificationsent'); - - // Conditionally launch add field inactivedate. - if (!$dbman->field_exists($table, $field)) { - $dbman->add_field($table, $field); - } - - // Monitor savepoint reached. - upgrade_plugin_savepoint(true, 2016052305, 'tool', 'monitor'); - } - - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - if ($oldversion < 2017021300) { // Delete "orphaned" subscriptions. diff --git a/admin/tool/usertours/db/upgrade.php b/admin/tool/usertours/db/upgrade.php index 9bdf9eec4d598..a8582de28fbba 100644 --- a/admin/tool/usertours/db/upgrade.php +++ b/admin/tool/usertours/db/upgrade.php @@ -35,9 +35,6 @@ function xmldb_tool_usertours_upgrade($oldversion) { global $CFG, $DB; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/auth/cas/db/upgrade.php b/auth/cas/db/upgrade.php index 469661c469bd6..4df297c456f49 100644 --- a/auth/cas/db/upgrade.php +++ b/auth/cas/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_auth_cas_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - if ($oldversion < 2017020700) { // Convert info in config plugins from auth/cas to auth_cas. upgrade_fix_config_auth_plugin_names('cas'); diff --git a/auth/db/db/upgrade.php b/auth/db/db/upgrade.php index 7955ffe9696a6..f860220094323 100644 --- a/auth/db/db/upgrade.php +++ b/auth/db/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_auth_db_upgrade($oldversion) { global $CFG, $DB; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - if ($oldversion < 2017032800) { // Convert info in config plugins from auth/db to auth_db upgrade_fix_config_auth_plugin_names('db'); diff --git a/auth/email/db/upgrade.php b/auth/email/db/upgrade.php index f00705bfa519f..f636d6ff99fa2 100644 --- a/auth/email/db/upgrade.php +++ b/auth/email/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_auth_email_upgrade($oldversion) { global $CFG, $DB; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - if ($oldversion < 2017020700) { // Convert info in config plugins from auth/email to auth_email. upgrade_fix_config_auth_plugin_names('email'); diff --git a/auth/ldap/db/upgrade.php b/auth/ldap/db/upgrade.php index 0a4c34455b2de..6c5725574d824 100644 --- a/auth/ldap/db/upgrade.php +++ b/auth/ldap/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_auth_ldap_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - if ($oldversion < 2017020700) { // Convert info in config plugins from auth/ldap to auth_ldap. upgrade_fix_config_auth_plugin_names('ldap'); diff --git a/auth/manual/db/upgrade.php b/auth/manual/db/upgrade.php index d691552f7e548..9209e9dcffdab 100644 --- a/auth/manual/db/upgrade.php +++ b/auth/manual/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_auth_manual_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - if ($oldversion < 2017020700) { // Convert info in config plugins from auth/manual to auth_manual. upgrade_fix_config_auth_plugin_names('manual'); diff --git a/auth/mnet/db/upgrade.php b/auth/mnet/db/upgrade.php index 7d4d88d57f1cb..be29bcd6c88dc 100644 --- a/auth/mnet/db/upgrade.php +++ b/auth/mnet/db/upgrade.php @@ -32,8 +32,6 @@ function xmldb_auth_mnet_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. if ($oldversion < 2017020700) { // Convert info in config plugins from auth/mnet to auth_mnet. upgrade_fix_config_auth_plugin_names('mnet'); diff --git a/auth/none/db/upgrade.php b/auth/none/db/upgrade.php index 596740baf72fd..2d5fc97003034 100644 --- a/auth/none/db/upgrade.php +++ b/auth/none/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_auth_none_upgrade($oldversion) { global $CFG, $DB; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - if ($oldversion < 2017020700) { // Convert info in config plugins from auth/none to auth_none. upgrade_fix_config_auth_plugin_names('none'); diff --git a/auth/oauth2/db/upgrade.php b/auth/oauth2/db/upgrade.php index 8d0a6a6a0f2fb..7582cc9ce9d83 100644 --- a/auth/oauth2/db/upgrade.php +++ b/auth/oauth2/db/upgrade.php @@ -35,9 +35,6 @@ function xmldb_auth_oauth2_upgrade($oldversion) { $dbman = $DB->get_manager(); - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/auth/shibboleth/db/upgrade.php b/auth/shibboleth/db/upgrade.php index 416ac20c2217e..640a02350ce06 100644 --- a/auth/shibboleth/db/upgrade.php +++ b/auth/shibboleth/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_auth_shibboleth_upgrade($oldversion) { global $CFG, $DB; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - if ($oldversion < 2017020700) { // Convert info in config plugins from auth/shibboleth to auth_shibboleth. upgrade_fix_config_auth_plugin_names('shibboleth'); diff --git a/blocks/badges/db/upgrade.php b/blocks/badges/db/upgrade.php index 433e0c7518964..6948646ed2df0 100644 --- a/blocks/badges/db/upgrade.php +++ b/blocks/badges/db/upgrade.php @@ -45,9 +45,6 @@ function xmldb_block_badges_upgrade($oldversion, $block) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/blocks/calendar_month/db/upgrade.php b/blocks/calendar_month/db/upgrade.php index 913ccca44d6dd..32051277b3baf 100644 --- a/blocks/calendar_month/db/upgrade.php +++ b/blocks/calendar_month/db/upgrade.php @@ -45,9 +45,6 @@ function xmldb_block_calendar_month_upgrade($oldversion, $block) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/blocks/calendar_upcoming/db/upgrade.php b/blocks/calendar_upcoming/db/upgrade.php index b1e95d61fd811..14100c83782ef 100644 --- a/blocks/calendar_upcoming/db/upgrade.php +++ b/blocks/calendar_upcoming/db/upgrade.php @@ -45,9 +45,6 @@ function xmldb_block_calendar_upcoming_upgrade($oldversion, $block) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/blocks/community/db/upgrade.php b/blocks/community/db/upgrade.php index ecfdca94d7dbf..0bdc51e15f01b 100644 --- a/blocks/community/db/upgrade.php +++ b/blocks/community/db/upgrade.php @@ -46,9 +46,6 @@ function xmldb_block_community_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/blocks/completionstatus/db/upgrade.php b/blocks/completionstatus/db/upgrade.php index 770a27bc00eea..8a9ec8966cf84 100644 --- a/blocks/completionstatus/db/upgrade.php +++ b/blocks/completionstatus/db/upgrade.php @@ -48,9 +48,6 @@ function xmldb_block_completionstatus_upgrade($oldversion, $block) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/blocks/course_summary/db/upgrade.php b/blocks/course_summary/db/upgrade.php index f3d591b134a4e..fb0cbaefb3138 100644 --- a/blocks/course_summary/db/upgrade.php +++ b/blocks/course_summary/db/upgrade.php @@ -48,9 +48,6 @@ function xmldb_block_course_summary_upgrade($oldversion, $block) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/blocks/html/db/upgrade.php b/blocks/html/db/upgrade.php index 221dd386bdb6c..4949b3f3a17b6 100644 --- a/blocks/html/db/upgrade.php +++ b/blocks/html/db/upgrade.php @@ -33,9 +33,6 @@ function xmldb_block_html_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/blocks/navigation/db/upgrade.php b/blocks/navigation/db/upgrade.php index fcd820a176f2c..97b106317ca71 100644 --- a/blocks/navigation/db/upgrade.php +++ b/blocks/navigation/db/upgrade.php @@ -55,9 +55,6 @@ function xmldb_block_navigation_upgrade($oldversion, $block) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/blocks/quiz_results/db/upgrade.php b/blocks/quiz_results/db/upgrade.php index a9ef40e432eca..60b035ecaebaa 100644 --- a/blocks/quiz_results/db/upgrade.php +++ b/blocks/quiz_results/db/upgrade.php @@ -45,9 +45,6 @@ function xmldb_block_quiz_results_upgrade($oldversion, $block) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/blocks/recent_activity/db/upgrade.php b/blocks/recent_activity/db/upgrade.php index 148cd378aa076..77e6f61c86165 100644 --- a/blocks/recent_activity/db/upgrade.php +++ b/blocks/recent_activity/db/upgrade.php @@ -47,9 +47,6 @@ function xmldb_block_recent_activity_upgrade($oldversion, $block) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/blocks/rss_client/db/upgrade.php b/blocks/rss_client/db/upgrade.php index ee46406acec58..878f198c3f947 100644 --- a/blocks/rss_client/db/upgrade.php +++ b/blocks/rss_client/db/upgrade.php @@ -33,9 +33,6 @@ function xmldb_block_rss_client_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/blocks/section_links/db/upgrade.php b/blocks/section_links/db/upgrade.php index a8e7bfd765cd5..0a8e2b0421b9c 100644 --- a/blocks/section_links/db/upgrade.php +++ b/blocks/section_links/db/upgrade.php @@ -49,9 +49,6 @@ function xmldb_block_section_links_upgrade($oldversion, $block) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/blocks/selfcompletion/db/upgrade.php b/blocks/selfcompletion/db/upgrade.php index 34a981429bfe0..9b8d87bddb055 100644 --- a/blocks/selfcompletion/db/upgrade.php +++ b/blocks/selfcompletion/db/upgrade.php @@ -48,9 +48,6 @@ function xmldb_block_selfcompletion_upgrade($oldversion, $block) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/blocks/settings/db/upgrade.php b/blocks/settings/db/upgrade.php index 3e93f8bfa865a..7b8618d76b6ad 100644 --- a/blocks/settings/db/upgrade.php +++ b/blocks/settings/db/upgrade.php @@ -55,9 +55,6 @@ function xmldb_block_settings_upgrade($oldversion, $block) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/enrol/database/db/upgrade.php b/enrol/database/db/upgrade.php index 9ba32618b2d21..ca2733c53cb7c 100644 --- a/enrol/database/db/upgrade.php +++ b/enrol/database/db/upgrade.php @@ -27,9 +27,6 @@ function xmldb_enrol_database_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/enrol/flatfile/db/upgrade.php b/enrol/flatfile/db/upgrade.php index adc61cbebbf89..c286910f29c8e 100644 --- a/enrol/flatfile/db/upgrade.php +++ b/enrol/flatfile/db/upgrade.php @@ -27,9 +27,6 @@ function xmldb_enrol_flatfile_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/enrol/guest/db/upgrade.php b/enrol/guest/db/upgrade.php index e86cfff1a1e0c..a4f9d25eb980b 100644 --- a/enrol/guest/db/upgrade.php +++ b/enrol/guest/db/upgrade.php @@ -27,9 +27,6 @@ function xmldb_enrol_guest_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/enrol/imsenterprise/db/upgrade.php b/enrol/imsenterprise/db/upgrade.php index 857eb62730456..d89f2962cbad4 100644 --- a/enrol/imsenterprise/db/upgrade.php +++ b/enrol/imsenterprise/db/upgrade.php @@ -33,9 +33,6 @@ function xmldb_enrol_imsenterprise_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/enrol/lti/db/upgrade.php b/enrol/lti/db/upgrade.php index cccd6ae3e7545..7b5736b44a54d 100644 --- a/enrol/lti/db/upgrade.php +++ b/enrol/lti/db/upgrade.php @@ -41,210 +41,6 @@ function xmldb_enrol_lti_upgrade($oldversion) { $dbman = $DB->get_manager(); - if ($oldversion < 2016052303) { - - // Define table enrol_lti_lti2_consumer to be created. - $table = new xmldb_table('enrol_lti_lti2_consumer'); - - // Adding fields to table enrol_lti_lti2_consumer. - $table->add_field('id', XMLDB_TYPE_INTEGER, '11', null, XMLDB_NOTNULL, XMLDB_SEQUENCE, null); - $table->add_field('name', XMLDB_TYPE_CHAR, '50', null, XMLDB_NOTNULL, null, null); - $table->add_field('consumerkey256', XMLDB_TYPE_CHAR, '255', null, XMLDB_NOTNULL, null, null); - $table->add_field('consumerkey', XMLDB_TYPE_TEXT, null, null, null, null, null); - $table->add_field('secret', XMLDB_TYPE_CHAR, '1024', null, XMLDB_NOTNULL, null, null); - $table->add_field('ltiversion', XMLDB_TYPE_CHAR, '10', null, null, null, null); - $table->add_field('consumername', XMLDB_TYPE_CHAR, '255', null, null, null, null); - $table->add_field('consumerversion', XMLDB_TYPE_CHAR, '255', null, null, null, null); - $table->add_field('consumerguid', XMLDB_TYPE_CHAR, '1024', null, null, null, null); - $table->add_field('profile', XMLDB_TYPE_TEXT, null, null, null, null, null); - $table->add_field('toolproxy', XMLDB_TYPE_TEXT, null, null, null, null, null); - $table->add_field('settings', XMLDB_TYPE_TEXT, null, null, null, null, null); - $table->add_field('protected', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, null); - $table->add_field('enabled', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, null); - $table->add_field('enablefrom', XMLDB_TYPE_INTEGER, '10', null, null, null, null); - $table->add_field('enableuntil', XMLDB_TYPE_INTEGER, '10', null, null, null, null); - $table->add_field('lastaccess', XMLDB_TYPE_INTEGER, '10', null, null, null, null); - $table->add_field('created', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, null, null); - $table->add_field('updated', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, null, null); - - // Adding keys to table enrol_lti_lti2_consumer. - $table->add_key('primary', XMLDB_KEY_PRIMARY, array('id')); - - // Adding indexes to table enrol_lti_lti2_consumer. - $table->add_index('consumerkey256_uniq', XMLDB_INDEX_UNIQUE, array('consumerkey256')); - - // Conditionally launch create table for enrol_lti_lti2_consumer. - if (!$dbman->table_exists($table)) { - $dbman->create_table($table); - } - - // Define table enrol_lti_lti2_tool_proxy to be created. - $table = new xmldb_table('enrol_lti_lti2_tool_proxy'); - - // Adding fields to table enrol_lti_lti2_tool_proxy. - $table->add_field('id', XMLDB_TYPE_INTEGER, '11', null, XMLDB_NOTNULL, XMLDB_SEQUENCE, null); - $table->add_field('toolproxykey', XMLDB_TYPE_CHAR, '32', null, XMLDB_NOTNULL, null, null); - $table->add_field('consumerid', XMLDB_TYPE_INTEGER, '11', null, XMLDB_NOTNULL, null, null); - $table->add_field('toolproxy', XMLDB_TYPE_TEXT, null, null, XMLDB_NOTNULL, null, null); - $table->add_field('created', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, null, null); - $table->add_field('updated', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, null, null); - - // Adding keys to table enrol_lti_lti2_tool_proxy. - $table->add_key('primary', XMLDB_KEY_PRIMARY, array('id')); - $table->add_key('toolproxykey_uniq', XMLDB_KEY_UNIQUE, array('toolproxykey')); - $table->add_key('consumerid', XMLDB_KEY_FOREIGN, array('consumerid'), 'enrol_lti_lti2_consumer', array('id')); - - // Conditionally launch create table for enrol_lti_lti2_tool_proxy. - if (!$dbman->table_exists($table)) { - $dbman->create_table($table); - } - - // Define table enrol_lti_lti2_context to be created. - $table = new xmldb_table('enrol_lti_lti2_context'); - - // Adding fields to table enrol_lti_lti2_context. - $table->add_field('id', XMLDB_TYPE_INTEGER, '11', null, XMLDB_NOTNULL, XMLDB_SEQUENCE, null); - $table->add_field('consumerid', XMLDB_TYPE_INTEGER, '11', null, XMLDB_NOTNULL, null, null); - $table->add_field('lticontextkey', XMLDB_TYPE_CHAR, '255', null, XMLDB_NOTNULL, null, null); - $table->add_field('settings', XMLDB_TYPE_TEXT, null, null, null, null, null); - $table->add_field('created', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, null, null); - $table->add_field('updated', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, null, null); - - // Adding keys to table enrol_lti_lti2_context. - $table->add_key('primary', XMLDB_KEY_PRIMARY, array('id')); - $table->add_key('consumerid', XMLDB_KEY_FOREIGN, array('consumerid'), 'enrol_lti_lti2_consumer', array('id')); - - // Conditionally launch create table for enrol_lti_lti2_context. - if (!$dbman->table_exists($table)) { - $dbman->create_table($table); - } - - // Define table enrol_lti_lti2_nonce to be created. - $table = new xmldb_table('enrol_lti_lti2_nonce'); - - // Adding fields to table enrol_lti_lti2_nonce. - $table->add_field('id', XMLDB_TYPE_INTEGER, '11', null, XMLDB_NOTNULL, XMLDB_SEQUENCE, null); - $table->add_field('consumerid', XMLDB_TYPE_INTEGER, '11', null, XMLDB_NOTNULL, null, null); - $table->add_field('value', XMLDB_TYPE_CHAR, '32', null, XMLDB_NOTNULL, null, null); - $table->add_field('expires', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, null, null); - - // Adding keys to table enrol_lti_lti2_nonce. - $table->add_key('primary', XMLDB_KEY_PRIMARY, array('id')); - $table->add_key('consumerid', XMLDB_KEY_FOREIGN, array('consumerid'), 'enrol_lti_lti2_consumer', array('id')); - - // Conditionally launch create table for enrol_lti_lti2_nonce. - if (!$dbman->table_exists($table)) { - $dbman->create_table($table); - } - - // Define table enrol_lti_lti2_resource_link to be created. - $table = new xmldb_table('enrol_lti_lti2_resource_link'); - - // Adding fields to table enrol_lti_lti2_resource_link. - $table->add_field('id', XMLDB_TYPE_INTEGER, '11', null, XMLDB_NOTNULL, XMLDB_SEQUENCE, null); - $table->add_field('contextid', XMLDB_TYPE_INTEGER, '11', null, null, null, null); - $table->add_field('consumerid', XMLDB_TYPE_INTEGER, '11', null, null, null, null); - $table->add_field('ltiresourcelinkkey', XMLDB_TYPE_CHAR, '255', null, XMLDB_NOTNULL, null, null); - $table->add_field('settings', XMLDB_TYPE_TEXT, null, null, null, null, null); - $table->add_field('primaryresourcelinkid', XMLDB_TYPE_INTEGER, '11', null, null, null, null); - $table->add_field('shareapproved', XMLDB_TYPE_INTEGER, '1', null, null, null, null); - $table->add_field('created', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, null, null); - $table->add_field('updated', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, null, null); - - // Adding keys to table enrol_lti_lti2_resource_link. - $table->add_key('primary', XMLDB_KEY_PRIMARY, array('id')); - $table->add_key('contextid', XMLDB_KEY_FOREIGN, array('contextid'), 'enrol_lti_lti2_context', array('id')); - $table->add_key('primaryresourcelinkid', XMLDB_KEY_FOREIGN, array('primaryresourcelinkid'), - 'enrol_lti_lti2_resource_link', array('id')); - $table->add_key('consumerid', XMLDB_KEY_FOREIGN, array('consumerid'), 'enrol_lti_lti2_consumer', array('id')); - - // Conditionally launch create table for enrol_lti_lti2_resource_link. - if (!$dbman->table_exists($table)) { - $dbman->create_table($table); - } - - // Define table enrol_lti_lti2_share_key to be created. - $table = new xmldb_table('enrol_lti_lti2_share_key'); - - // Adding fields to table enrol_lti_lti2_share_key. - $table->add_field('id', XMLDB_TYPE_INTEGER, '11', null, XMLDB_NOTNULL, XMLDB_SEQUENCE, null); - $table->add_field('sharekey', XMLDB_TYPE_CHAR, '32', null, XMLDB_NOTNULL, null, null); - $table->add_field('resourcelinkid', XMLDB_TYPE_INTEGER, '11', null, XMLDB_NOTNULL, null, null); - $table->add_field('autoapprove', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, null); - $table->add_field('expires', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, null, null); - - // Adding keys to table enrol_lti_lti2_share_key. - $table->add_key('primary', XMLDB_KEY_PRIMARY, array('id')); - $table->add_key('sharekey', XMLDB_KEY_UNIQUE, array('sharekey')); - $table->add_key('resourcelinkid', XMLDB_KEY_FOREIGN_UNIQUE, array('resourcelinkid'), - 'enrol_lti_lti2_resource_link', array('id')); - - // Conditionally launch create table for enrol_lti_lti2_share_key. - if (!$dbman->table_exists($table)) { - $dbman->create_table($table); - } - - // Define table enrol_lti_lti2_user_result to be created. - $table = new xmldb_table('enrol_lti_lti2_user_result'); - - // Adding fields to table enrol_lti_lti2_user_result. - $table->add_field('id', XMLDB_TYPE_INTEGER, '11', null, XMLDB_NOTNULL, XMLDB_SEQUENCE, null); - $table->add_field('resourcelinkid', XMLDB_TYPE_INTEGER, '11', null, XMLDB_NOTNULL, null, null); - $table->add_field('ltiuserkey', XMLDB_TYPE_CHAR, '255', null, XMLDB_NOTNULL, null, null); - $table->add_field('ltiresultsourcedid', XMLDB_TYPE_CHAR, '1024', null, XMLDB_NOTNULL, null, null); - $table->add_field('created', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, null, null); - $table->add_field('updated', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, null, null); - - // Adding keys to table enrol_lti_lti2_user_result. - $table->add_key('primary', XMLDB_KEY_PRIMARY, array('id')); - $table->add_key('resourcelinkid', XMLDB_KEY_FOREIGN, array('resourcelinkid'), - 'enrol_lti_lti2_resource_link', array('id')); - - // Conditionally launch create table for enrol_lti_lti2_user_result. - if (!$dbman->table_exists($table)) { - $dbman->create_table($table); - } - - // Define table enrol_lti_tool_consumer_map to be created. - $table = new xmldb_table('enrol_lti_tool_consumer_map'); - - // Adding fields to table enrol_lti_tool_consumer_map. - $table->add_field('id', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, XMLDB_SEQUENCE, null); - $table->add_field('toolid', XMLDB_TYPE_INTEGER, '11', null, XMLDB_NOTNULL, null, null); - $table->add_field('consumerid', XMLDB_TYPE_INTEGER, '11', null, XMLDB_NOTNULL, null, null); - - // Adding keys to table enrol_lti_tool_consumer_map. - $table->add_key('primary', XMLDB_KEY_PRIMARY, array('id')); - $table->add_key('toolid', XMLDB_KEY_FOREIGN, array('toolid'), 'enrol_lti_tools', array('id')); - $table->add_key('consumerid', XMLDB_KEY_FOREIGN, array('consumerid'), 'enrol_lti_lti2_consumer', array('id')); - - // Conditionally launch create table for enrol_lti_tool_consumer_map. - if (!$dbman->table_exists($table)) { - $dbman->create_table($table); - } - - // Lti savepoint reached. - upgrade_plugin_savepoint(true, 2016052303, 'enrol', 'lti'); - } - - if ($oldversion < 2016052304) { - - // Define field type to be added to enrol_lti_lti2_context. - $table = new xmldb_table('enrol_lti_lti2_context'); - $field = new xmldb_field('type', XMLDB_TYPE_CHAR, '100', null, null, null, null, 'lticontextkey'); - - // Conditionally launch add field type. - if (!$dbman->field_exists($table, $field)) { - $dbman->add_field($table, $field); - } - - // Lti savepoint reached. - upgrade_plugin_savepoint(true, 2016052304, 'enrol', 'lti'); - } - - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - if ($oldversion < 2017011300) { // Changing precision of field value on table enrol_lti_lti2_nonce to (64). diff --git a/enrol/manual/db/upgrade.php b/enrol/manual/db/upgrade.php index 9d3b9673d5169..48dfc6929bf63 100644 --- a/enrol/manual/db/upgrade.php +++ b/enrol/manual/db/upgrade.php @@ -27,9 +27,6 @@ function xmldb_enrol_manual_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/enrol/mnet/db/upgrade.php b/enrol/mnet/db/upgrade.php index e42f78f125f27..f6d9efb4af0ac 100644 --- a/enrol/mnet/db/upgrade.php +++ b/enrol/mnet/db/upgrade.php @@ -27,9 +27,6 @@ function xmldb_enrol_mnet_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/enrol/paypal/db/upgrade.php b/enrol/paypal/db/upgrade.php index 5732fe2c4d8d7..93ebd504d81f6 100644 --- a/enrol/paypal/db/upgrade.php +++ b/enrol/paypal/db/upgrade.php @@ -47,9 +47,6 @@ function xmldb_enrol_paypal_upgrade($oldversion) { $dbman = $DB->get_manager(); - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/enrol/self/db/upgrade.php b/enrol/self/db/upgrade.php index 6436e7c700a2e..cb255e8bf6dd5 100644 --- a/enrol/self/db/upgrade.php +++ b/enrol/self/db/upgrade.php @@ -25,25 +25,7 @@ defined('MOODLE_INTERNAL') || die(); function xmldb_enrol_self_upgrade($oldversion) { - global $CFG, $DB; - - if ($oldversion < 2016052301) { - // Get roles with manager archetype. - $managerroles = get_archetype_roles('manager'); - if (!empty($managerroles)) { - // Remove wrong CAP_PROHIBIT from self:holdkey. - foreach ($managerroles as $role) { - $DB->execute("DELETE - FROM {role_capabilities} - WHERE roleid = ? AND capability = ? AND permission = ?", - array($role->id, 'enrol/self:holdkey', CAP_PROHIBIT)); - } - } - upgrade_plugin_savepoint(true, 2016052301, 'enrol', 'self'); - } - - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. + global $CFG; // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/filter/mathjaxloader/db/upgrade.php b/filter/mathjaxloader/db/upgrade.php index 754152cf66baf..e4bb953f13d25 100644 --- a/filter/mathjaxloader/db/upgrade.php +++ b/filter/mathjaxloader/db/upgrade.php @@ -33,35 +33,6 @@ function xmldb_filter_mathjaxloader_upgrade($oldversion) { require_once($CFG->dirroot . '/filter/mathjaxloader/db/upgradelib.php'); - if ($oldversion < 2016080200) { - // We are consolodating the two settings for http and https url into only the https - // setting. Since it is preferably to always load the secure resource. - - $httpurl = get_config('filter_mathjaxloader', 'httpurl'); - if ($httpurl !== 'http://cdn.mathjax.org/mathjax/2.6-latest/MathJax.js' && - $httpurl !== 'http://cdn.mathjax.org/mathjax/2.6.1/MathJax.js') { - // If the http setting has been changed, we make the admin choose the https setting because - // it indicates some sort of custom setup. This will be supported by the release notes. - unset_config('httpsurl', 'filter_mathjaxloader'); - } - - // The seperate http setting has been removed. We always use the secure resource. - unset_config('httpurl', 'filter_mathjaxloader'); - - upgrade_plugin_savepoint(true, 2016080200, 'filter', 'mathjaxloader'); - } - - if ($oldversion < 2016102500) { - $httpsurl = get_config('filter_mathjaxloader', 'httpsurl'); - if ($httpsurl === "https://cdn.mathjax.org/mathjax/2.6-latest/MathJax.js") { - set_config('httpsurl', 'https://cdn.mathjax.org/mathjax/2.7-latest/MathJax.js', 'filter_mathjaxloader'); - } - upgrade_plugin_savepoint(true, 2016102500, 'filter', 'mathjaxloader'); - } - - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // if ($oldversion < 2017040300) { $httpsurl = get_config('filter_mathjaxloader', 'httpsurl'); diff --git a/filter/mediaplugin/db/upgrade.php b/filter/mediaplugin/db/upgrade.php index 09391c3e13036..a8a43ac6634ef 100644 --- a/filter/mediaplugin/db/upgrade.php +++ b/filter/mediaplugin/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_filter_mediaplugin_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/filter/tex/db/upgrade.php b/filter/tex/db/upgrade.php index da0d43aa84371..ec40486e27dda 100644 --- a/filter/tex/db/upgrade.php +++ b/filter/tex/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_filter_tex_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/grade/grading/form/guide/db/upgrade.php b/grade/grading/form/guide/db/upgrade.php index e781e99823001..290350d3cdd19 100644 --- a/grade/grading/form/guide/db/upgrade.php +++ b/grade/grading/form/guide/db/upgrade.php @@ -37,9 +37,6 @@ function xmldb_gradingform_guide_upgrade($oldversion) { global $DB; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/grade/grading/form/rubric/db/upgrade.php b/grade/grading/form/rubric/db/upgrade.php index a48635ca91d60..e7e0bdf5c63fe 100644 --- a/grade/grading/form/rubric/db/upgrade.php +++ b/grade/grading/form/rubric/db/upgrade.php @@ -33,9 +33,6 @@ function xmldb_gradingform_rubric_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/grade/report/user/db/upgrade.php b/grade/report/user/db/upgrade.php index a2d24968224c0..bc436ed2c3b9b 100644 --- a/grade/report/user/db/upgrade.php +++ b/grade/report/user/db/upgrade.php @@ -29,9 +29,6 @@ function xmldb_gradereport_user_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/lib/antivirus/clamav/db/upgrade.php b/lib/antivirus/clamav/db/upgrade.php index 2ff3f9f584432..493f0fd5dcac6 100644 --- a/lib/antivirus/clamav/db/upgrade.php +++ b/lib/antivirus/clamav/db/upgrade.php @@ -32,25 +32,6 @@ */ function xmldb_antivirus_clamav_upgrade($oldversion) { - if ($oldversion < 2016101700) { - // Remove setting that has been deprecated long time ago at MDL-44260. - unset_config('quarantinedir', 'antivirus_clamav'); - upgrade_plugin_savepoint(true, 2016101700, 'antivirus', 'clamav'); - } - - if ($oldversion < 2016102600) { - // Make command line a default running method for now. We depend on this - // config variable in antivirus scan running, it should be defined. - if (!get_config('antivirus_clamav', 'runningmethod')) { - set_config('runningmethod', 'commandline', 'antivirus_clamav'); - } - - upgrade_plugin_savepoint(true, 2016102600, 'antivirus', 'clamav'); - } - - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/lib/db/upgrade.php b/lib/db/upgrade.php index 35cf1da0dff65..eb00748dcbd26 100644 --- a/lib/db/upgrade.php +++ b/lib/db/upgrade.php @@ -92,388 +92,15 @@ function xmldb_main_upgrade($oldversion) { $dbman = $DB->get_manager(); // Loads ddl manager and xmldb classes. // Always keep this upgrade step with version being the minimum - // allowed version to upgrade from (v3.1.0 right now). - if ($oldversion < 2016052300) { + // allowed version to upgrade from (v3.2.0 right now). + if ($oldversion < 2016120500) { // Just in case somebody hacks upgrade scripts or env, we really can not continue. - echo("You need to upgrade to 3.1.x or higher first!\n"); + echo("You need to upgrade to 3.2.x or higher first!\n"); exit(1); // Note this savepoint is 100% unreachable, but needed to pass the upgrade checks. - upgrade_main_savepoint(true, 2016052300); + upgrade_main_savepoint(true, 2016120500); } - if ($oldversion < 2016081700.00) { - - // If someone is emotionally attached to it let's leave the config (basically the version) there. - if (!file_exists($CFG->dirroot . '/report/search/classes/output/form.php')) { - unset_all_config_for_plugin('report_search'); - } - - // Savepoint reached. - upgrade_main_savepoint(true, 2016081700.00); - } - - if ($oldversion < 2016081700.02) { - // Default schedule values. - $hour = 0; - $minute = 0; - - // Get the old settings. - if (isset($CFG->statsruntimestarthour)) { - $hour = $CFG->statsruntimestarthour; - } - if (isset($CFG->statsruntimestartminute)) { - $minute = $CFG->statsruntimestartminute; - } - - // Retrieve the scheduled task record first. - $stattask = $DB->get_record('task_scheduled', array('component' => 'moodle', 'classname' => '\core\task\stats_cron_task')); - - // Don't touch customised scheduling. - if ($stattask && !$stattask->customised) { - - $nextruntime = mktime($hour, $minute, 0, date('m'), date('d'), date('Y')); - if ($nextruntime < $stattask->lastruntime) { - // Add 24 hours to the next run time. - $newtime = new DateTime(); - $newtime->setTimestamp($nextruntime); - $newtime->add(new DateInterval('P1D')); - $nextruntime = $newtime->getTimestamp(); - } - $stattask->nextruntime = $nextruntime; - $stattask->minute = $minute; - $stattask->hour = $hour; - $stattask->customised = 1; - $DB->update_record('task_scheduled', $stattask); - } - // These settings are no longer used. - unset_config('statsruntimestarthour'); - unset_config('statsruntimestartminute'); - unset_config('statslastexecution'); - - upgrade_main_savepoint(true, 2016081700.02); - } - - if ($oldversion < 2016082200.00) { - // An upgrade step to remove any duplicate stamps, within the same context, in the question_categories table, and to - // add a unique index to (contextid, stamp) to avoid future stamp duplication. See MDL-54864. - - // Extend the execution time limit of the script to 2 hours. - upgrade_set_timeout(7200); - - // This SQL fetches the id of those records which have duplicate stamps within the same context. - // This doesn't return the original record within the context, from which the duplicate stamps were likely created. - $fromclause = "FROM ( - SELECT min(id) AS minid, contextid, stamp - FROM {question_categories} - GROUP BY contextid, stamp - ) minid - JOIN {question_categories} qc - ON qc.contextid = minid.contextid AND qc.stamp = minid.stamp AND qc.id > minid.minid"; - - // Get the total record count - used for the progress bar. - $countduplicatessql = "SELECT count(qc.id) $fromclause"; - $total = $DB->count_records_sql($countduplicatessql); - - // Get the records themselves. - $getduplicatessql = "SELECT qc.id $fromclause ORDER BY minid"; - $rs = $DB->get_recordset_sql($getduplicatessql); - - // For each duplicate, update the stamp to a new random value. - $i = 0; - $pbar = new progress_bar('updatequestioncategorystamp', 500, true); - foreach ($rs as $record) { - // Generate a new, unique stamp and update the record. - do { - $newstamp = make_unique_id_code(); - } while (isset($usedstamps[$newstamp])); - $usedstamps[$newstamp] = 1; - $DB->set_field('question_categories', 'stamp', $newstamp, array('id' => $record->id)); - - // Update progress. - $i++; - $pbar->update($i, $total, "Updating duplicate question category stamp - $i/$total."); - } - $rs->close(); - unset($usedstamps); - - // The uniqueness of each (contextid, stamp) pair is now guaranteed, so add the unique index to stop future duplicates. - $table = new xmldb_table('question_categories'); - $index = new xmldb_index('contextidstamp', XMLDB_INDEX_UNIQUE, array('contextid', 'stamp')); - if (!$dbman->index_exists($table, $index)) { - $dbman->add_index($table, $index); - } - - // Savepoint reached. - upgrade_main_savepoint(true, 2016082200.00); - } - - if ($oldversion < 2016091900.00) { - - // Removing the themes from core. - $themes = array('base', 'canvas'); - - foreach ($themes as $key => $theme) { - if (check_dir_exists($CFG->dirroot . '/theme/' . $theme, false)) { - // Ignore the themes that have been re-downloaded. - unset($themes[$key]); - } - } - - if (!empty($themes)) { - // Hacky emulation of plugin uninstallation. - foreach ($themes as $theme) { - unset_all_config_for_plugin('theme_' . $theme); - } - } - - // Main savepoint reached. - upgrade_main_savepoint(true, 2016091900.00); - } - - if ($oldversion < 2016091900.02) { - - // Define index attemptstepid-name (unique) to be dropped from question_attempt_step_data. - $table = new xmldb_table('question_attempt_step_data'); - $index = new xmldb_index('attemptstepid-name', XMLDB_INDEX_UNIQUE, array('attemptstepid', 'name')); - - // Conditionally launch drop index attemptstepid-name. - if ($dbman->index_exists($table, $index)) { - $dbman->drop_index($table, $index); - } - - // Main savepoint reached. - upgrade_main_savepoint(true, 2016091900.02); - } - - if ($oldversion < 2016100300.00) { - unset_config('enablecssoptimiser'); - - upgrade_main_savepoint(true, 2016100300.00); - } - - if ($oldversion < 2016100501.00) { - - // Define field enddate to be added to course. - $table = new xmldb_table('course'); - $field = new xmldb_field('enddate', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, null, '0', 'startdate'); - - // Conditionally launch add field enddate. - if (!$dbman->field_exists($table, $field)) { - $dbman->add_field($table, $field); - } - - // Main savepoint reached. - upgrade_main_savepoint(true, 2016100501.00); - } - - if ($oldversion < 2016101100.00) { - // Define field component to be added to message. - $table = new xmldb_table('message'); - $field = new xmldb_field('component', XMLDB_TYPE_CHAR, '100', null, null, null, null, 'timeusertodeleted'); - - // Conditionally launch add field component. - if (!$dbman->field_exists($table, $field)) { - $dbman->add_field($table, $field); - } - - // Define field eventtype to be added to message. - $field = new xmldb_field('eventtype', XMLDB_TYPE_CHAR, '100', null, null, null, null, 'component'); - - // Conditionally launch add field eventtype. - if (!$dbman->field_exists($table, $field)) { - $dbman->add_field($table, $field); - } - - // Main savepoint reached. - upgrade_main_savepoint(true, 2016101100.00); - } - - - if ($oldversion < 2016101101.00) { - // Define field component to be added to message_read. - $table = new xmldb_table('message_read'); - $field = new xmldb_field('component', XMLDB_TYPE_CHAR, '100', null, null, null, null, 'timeusertodeleted'); - - // Conditionally launch add field component. - if (!$dbman->field_exists($table, $field)) { - $dbman->add_field($table, $field); - } - - // Define field eventtype to be added to message_read. - $field = new xmldb_field('eventtype', XMLDB_TYPE_CHAR, '100', null, null, null, null, 'component'); - - // Conditionally launch add field eventtype. - if (!$dbman->field_exists($table, $field)) { - $dbman->add_field($table, $field); - } - - // Main savepoint reached. - upgrade_main_savepoint(true, 2016101101.00); - } - - if ($oldversion < 2016101401.00) { - // Clean up repository_alfresco config unless plugin has been manually installed. - if (!file_exists($CFG->dirroot . '/repository/alfresco/lib.php')) { - // Remove capabilities. - capabilities_cleanup('repository_alfresco'); - // Clean config. - unset_all_config_for_plugin('repository_alfresco'); - } - - // Savepoint reached. - upgrade_main_savepoint(true, 2016101401.00); - } - - if ($oldversion < 2016101401.02) { - $table = new xmldb_table('external_tokens'); - $field = new xmldb_field('privatetoken', XMLDB_TYPE_CHAR, '64', null, null, null, null); - - // Conditionally add privatetoken field to the external_tokens table. - if (!$dbman->field_exists($table, $field)) { - $dbman->add_field($table, $field); - } - - // Main savepoint reached. - upgrade_main_savepoint(true, 2016101401.02); - } - - if ($oldversion < 2016110202.00) { - - // Force uninstall of deleted authentication plugin. - if (!file_exists("$CFG->dirroot/auth/radius")) { - // Leave settings inplace if there are radius users. - if (!$DB->record_exists('user', array('auth' => 'radius', 'deleted' => 0))) { - // Remove all other associated config. - unset_all_config_for_plugin('auth/radius'); - // The version number for radius is in this format. - unset_all_config_for_plugin('auth_radius'); - } - } - upgrade_main_savepoint(true, 2016110202.00); - } - - if ($oldversion < 2016110300.00) { - // Remove unused admin email setting. - unset_config('emailonlyfromreplyaddress'); - - // Main savepoint reached. - upgrade_main_savepoint(true, 2016110300.00); - } - - if ($oldversion < 2016110500.00) { - - $oldplayers = [ - 'vimeo' => null, - 'mp3' => ['.mp3'], - 'html5video' => ['.mov', '.mp4', '.m4v', '.mpeg', '.mpe', '.mpg', '.ogv', '.webm'], - 'flv' => ['.flv', '.f4v'], - 'html5audio' => ['.aac', '.flac', '.mp3', '.m4a', '.oga', '.ogg', '.wav'], - 'youtube' => null, - 'swf' => null, - ]; - - // Convert hardcoded media players to the settings of the new media player plugin type. - if (get_config('core', 'media_plugins_sortorder') === false) { - $enabledplugins = []; - $videoextensions = []; - $audioextensions = []; - foreach ($oldplayers as $oldplayer => $extensions) { - $settingname = 'core_media_enable_'.$oldplayer; - if (!empty($CFG->$settingname)) { - if ($extensions) { - // VideoJS will be used for all media files players that were used previously. - $enabledplugins['videojs'] = 'videojs'; - if ($oldplayer === 'mp3' || $oldplayer === 'html5audio') { - $audioextensions += array_combine($extensions, $extensions); - } else { - $videoextensions += array_combine($extensions, $extensions); - } - } else { - // Enable youtube, vimeo and swf. - $enabledplugins[$oldplayer] = $oldplayer; - } - } - } - - set_config('media_plugins_sortorder', join(',', $enabledplugins)); - - // Configure VideoJS to match the existing players set up. - if ($enabledplugins['videojs']) { - $enabledplugins[] = 'videojs'; - set_config('audioextensions', join(',', $audioextensions), 'media_videojs'); - set_config('videoextensions', join(',', $videoextensions), 'media_videojs'); - $useflash = !empty($CFG->core_media_enable_flv) || !empty($CFG->core_media_enable_mp3); - set_config('useflash', $useflash, 'media_videojs'); - if (empty($CFG->core_media_enable_youtube)) { - // Normally YouTube is enabled in videojs, but if youtube converter was disabled before upgrade - // disable it in videojs as well. - set_config('youtube', false, 'media_videojs'); - } - } - } - - // Unset old settings. - foreach ($oldplayers as $oldplayer => $extensions) { - unset_config('core_media_enable_' . $oldplayer); - } - - // Preset defaults if CORE_MEDIA_VIDEO_WIDTH and CORE_MEDIA_VIDEO_HEIGHT are specified in config.php . - // After this upgrade step these constants will not be used any more. - if (defined('CORE_MEDIA_VIDEO_WIDTH')) { - set_config('media_default_width', CORE_MEDIA_VIDEO_WIDTH); - } - if (defined('CORE_MEDIA_VIDEO_HEIGHT')) { - set_config('media_default_height', CORE_MEDIA_VIDEO_HEIGHT); - } - - // Savepoint reached. - upgrade_main_savepoint(true, 2016110500.00); - } - - if ($oldversion < 2016110600.00) { - // Define a field 'deletioninprogress' in the 'course_modules' table, to background deletion tasks. - $table = new xmldb_table('course_modules'); - $field = new xmldb_field('deletioninprogress', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '0', 'availability'); - - // Conditionally launch add field 'deletioninprogress'. - if (!$dbman->field_exists($table, $field)) { - $dbman->add_field($table, $field); - } - - // Main savepoint reached. - upgrade_main_savepoint(true, 2016110600.00); - } - - if ($oldversion < 2016112200.01) { - - // Define field requiredbytheme to be added to block_instances. - $table = new xmldb_table('block_instances'); - $field = new xmldb_field('requiredbytheme', XMLDB_TYPE_INTEGER, '4', null, XMLDB_NOTNULL, null, '0', 'showinsubcontexts'); - - // Conditionally launch add field requiredbytheme. - if (!$dbman->field_exists($table, $field)) { - $dbman->add_field($table, $field); - } - - // Main savepoint reached. - upgrade_main_savepoint(true, 2016112200.01); - } - if ($oldversion < 2016112200.02) { - - // Change the existing site level admin and settings blocks to be requiredbytheme which means they won't show in boost. - $context = context_system::instance(); - $params = array('blockname' => 'settings', 'parentcontextid' => $context->id); - $DB->set_field('block_instances', 'requiredbytheme', 1, $params); - - $params = array('blockname' => 'navigation', 'parentcontextid' => $context->id); - $DB->set_field('block_instances', 'requiredbytheme', 1, $params); - // Main savepoint reached. - upgrade_main_savepoint(true, 2016112200.02); - } - - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - if ($oldversion < 2016122800.00) { // Find all roles with the coursecreator archetype. $coursecreatorroleids = $DB->get_records('role', array('archetype' => 'coursecreator'), '', 'id'); diff --git a/lib/editor/atto/db/upgrade.php b/lib/editor/atto/db/upgrade.php index c668c23a6b87b..2d91167ca5c63 100644 --- a/lib/editor/atto/db/upgrade.php +++ b/lib/editor/atto/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_editor_atto_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/lib/editor/atto/plugins/equation/db/upgrade.php b/lib/editor/atto/plugins/equation/db/upgrade.php index 0443ae8542f1e..e10c52f8f670a 100644 --- a/lib/editor/atto/plugins/equation/db/upgrade.php +++ b/lib/editor/atto/plugins/equation/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_atto_equation_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/lib/editor/tinymce/db/upgrade.php b/lib/editor/tinymce/db/upgrade.php index a6a09f342e747..76c25ef4749f9 100644 --- a/lib/editor/tinymce/db/upgrade.php +++ b/lib/editor/tinymce/db/upgrade.php @@ -27,9 +27,6 @@ function xmldb_editor_tinymce_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/lib/editor/tinymce/plugins/spellchecker/db/upgrade.php b/lib/editor/tinymce/plugins/spellchecker/db/upgrade.php index b387c7f0905d8..5408bf68fb20e 100644 --- a/lib/editor/tinymce/plugins/spellchecker/db/upgrade.php +++ b/lib/editor/tinymce/plugins/spellchecker/db/upgrade.php @@ -27,9 +27,6 @@ function xmldb_tinymce_spellchecker_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/message/output/email/db/upgrade.php b/message/output/email/db/upgrade.php index 3335d7f23cf2c..e7bb6de649069 100644 --- a/message/output/email/db/upgrade.php +++ b/message/output/email/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_message_email_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/message/output/jabber/db/upgrade.php b/message/output/jabber/db/upgrade.php index aa1681f11bdec..f27426cf4779d 100644 --- a/message/output/jabber/db/upgrade.php +++ b/message/output/jabber/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_message_jabber_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/message/output/popup/db/upgrade.php b/message/output/popup/db/upgrade.php index 3256057014066..5c179e50bbc52 100644 --- a/message/output/popup/db/upgrade.php +++ b/message/output/popup/db/upgrade.php @@ -34,34 +34,6 @@ function xmldb_message_popup_upgrade($oldversion) { $dbman = $DB->get_manager(); - if ($oldversion < 2016052309) { - - // Define table message_popup to be created. - $table = new xmldb_table('message_popup'); - - // Adding fields to table message_popup. - $table->add_field('id', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, XMLDB_SEQUENCE, null); - $table->add_field('messageid', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, null, null); - $table->add_field('isread', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '0'); - - // Adding keys to table message_popup. - $table->add_key('primary', XMLDB_KEY_PRIMARY, array('id')); - - // Adding indexes to table message_popup. - $table->add_index('messageid-isread', XMLDB_INDEX_UNIQUE, array('messageid', 'isread')); - - // Conditionally launch create table for message_popup. - if (!$dbman->table_exists($table)) { - $dbman->create_table($table); - } - - // Popup savepoint reached. - upgrade_plugin_savepoint(true, 2016052309, 'message', 'popup'); - } - - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - if ($oldversion < 2016122100) { // Define index isread (not unique) to be added to message_popup. diff --git a/mod/assign/db/upgrade.php b/mod/assign/db/upgrade.php index 3b7e4df262e93..18a0391a7486a 100644 --- a/mod/assign/db/upgrade.php +++ b/mod/assign/db/upgrade.php @@ -34,39 +34,6 @@ function xmldb_assign_upgrade($oldversion) { $dbman = $DB->get_manager(); - if ($oldversion < 2016100301) { - - // Define table assign_overrides to be created. - $table = new xmldb_table('assign_overrides'); - - // Adding fields to table assign_overrides. - $table->add_field('id', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, XMLDB_SEQUENCE, null); - $table->add_field('assignid', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, null, '0'); - $table->add_field('groupid', XMLDB_TYPE_INTEGER, '10', null, null, null, null); - $table->add_field('userid', XMLDB_TYPE_INTEGER, '10', null, null, null, null); - $table->add_field('sortorder', XMLDB_TYPE_INTEGER, '10', null, null, null, null); - $table->add_field('allowsubmissionsfromdate', XMLDB_TYPE_INTEGER, '10', null, null, null, null); - $table->add_field('duedate', XMLDB_TYPE_INTEGER, '10', null, null, null, null); - $table->add_field('cutoffdate', XMLDB_TYPE_INTEGER, '10', null, null, null, null); - - // Adding keys to table assign_overrides. - $table->add_key('primary', XMLDB_KEY_PRIMARY, array('id')); - $table->add_key('assignid', XMLDB_KEY_FOREIGN, array('assignid'), 'assign', array('id')); - $table->add_key('groupid', XMLDB_KEY_FOREIGN, array('groupid'), 'groups', array('id')); - $table->add_key('userid', XMLDB_KEY_FOREIGN, array('userid'), 'user', array('id')); - - // Conditionally launch create table for assign_overrides. - if (!$dbman->table_exists($table)) { - $dbman->create_table($table); - } - - // Assign savepoint reached. - upgrade_mod_savepoint(true, 2016100301, 'assign'); - } - - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - if ($oldversion < 2017021500) { // Fix event types of assign events. $params = [ @@ -129,6 +96,7 @@ function xmldb_assign_upgrade($oldversion) { // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. + if ($oldversion < 2017061200) { // Data fix any assign group override event priorities which may have been accidentally nulled due to a bug on the group // overrides edit form. diff --git a/mod/assign/feedback/comments/db/upgrade.php b/mod/assign/feedback/comments/db/upgrade.php index 1356de03451a4..ae87b98ad30f1 100644 --- a/mod/assign/feedback/comments/db/upgrade.php +++ b/mod/assign/feedback/comments/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_assignfeedback_comments_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/assign/feedback/editpdf/db/upgrade.php b/mod/assign/feedback/editpdf/db/upgrade.php index 61353d0e10ce8..2cd3cd98a0b07 100644 --- a/mod/assign/feedback/editpdf/db/upgrade.php +++ b/mod/assign/feedback/editpdf/db/upgrade.php @@ -34,9 +34,6 @@ function xmldb_assignfeedback_editpdf_upgrade($oldversion) { $dbman = $DB->get_manager(); - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - if ($oldversion < 2017022700) { // Get orphaned, duplicate files and delete them. diff --git a/mod/assign/feedback/file/db/upgrade.php b/mod/assign/feedback/file/db/upgrade.php index 72b6a3fa944cc..898839c128c8b 100644 --- a/mod/assign/feedback/file/db/upgrade.php +++ b/mod/assign/feedback/file/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_assignfeedback_file_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/assign/submission/comments/db/upgrade.php b/mod/assign/submission/comments/db/upgrade.php index 3955a1760d9e8..3c41dfe59f321 100644 --- a/mod/assign/submission/comments/db/upgrade.php +++ b/mod/assign/submission/comments/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_assignsubmission_comments_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/assign/submission/file/db/upgrade.php b/mod/assign/submission/file/db/upgrade.php index a62453a1340a4..2f6c544ab256e 100644 --- a/mod/assign/submission/file/db/upgrade.php +++ b/mod/assign/submission/file/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_assignsubmission_file_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/assign/submission/onlinetext/db/upgrade.php b/mod/assign/submission/onlinetext/db/upgrade.php index b362fb879f2db..2b04adaee19bd 100644 --- a/mod/assign/submission/onlinetext/db/upgrade.php +++ b/mod/assign/submission/onlinetext/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_assignsubmission_onlinetext_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/assignment/db/upgrade.php b/mod/assignment/db/upgrade.php index 16b0bccfb987c..a6187c6f52d6f 100644 --- a/mod/assignment/db/upgrade.php +++ b/mod/assignment/db/upgrade.php @@ -24,9 +24,6 @@ function xmldb_assignment_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/book/db/upgrade.php b/mod/book/db/upgrade.php index ee5c7fd314873..eeac64fbd9934 100644 --- a/mod/book/db/upgrade.php +++ b/mod/book/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_book_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/chat/db/upgrade.php b/mod/chat/db/upgrade.php index 9f8d3b462b931..5351271133c95 100644 --- a/mod/chat/db/upgrade.php +++ b/mod/chat/db/upgrade.php @@ -29,9 +29,6 @@ function xmldb_chat_upgrade($oldversion) { $dbman = $DB->get_manager(); - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/choice/db/upgrade.php b/mod/choice/db/upgrade.php index 9a04cb6c04311..31f2963797031 100644 --- a/mod/choice/db/upgrade.php +++ b/mod/choice/db/upgrade.php @@ -24,9 +24,6 @@ function xmldb_choice_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/data/db/upgrade.php b/mod/data/db/upgrade.php index 78e056efc688d..96d2f3592400e 100644 --- a/mod/data/db/upgrade.php +++ b/mod/data/db/upgrade.php @@ -26,24 +26,6 @@ function xmldb_data_upgrade($oldversion) { $dbman = $DB->get_manager(); - if ($oldversion < 2016090600) { - - // Define field config to be added to data. - $table = new xmldb_table('data'); - $field = new xmldb_field('config', XMLDB_TYPE_TEXT, null, null, null, null, null, 'timemodified'); - - // Conditionally launch add field config. - if (!$dbman->field_exists($table, $field)) { - $dbman->add_field($table, $field); - } - - // Data savepoint reached. - upgrade_mod_savepoint(true, 2016090600, 'data'); - } - - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - if ($oldversion < 2017032800) { // Define field completionentries to be added to data. Require a number of entries to be considered complete. diff --git a/mod/feedback/db/upgrade.php b/mod/feedback/db/upgrade.php index b21dfe82d7420..603521d8d6db3 100644 --- a/mod/feedback/db/upgrade.php +++ b/mod/feedback/db/upgrade.php @@ -41,9 +41,6 @@ function xmldb_feedback_upgrade($oldversion) { $dbman = $DB->get_manager(); // Loads ddl manager and xmldb classes. - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - if ($oldversion < 2017032800) { // Delete duplicated records in feedback_completed. We just keep the last record of completion. diff --git a/mod/folder/db/upgrade.php b/mod/folder/db/upgrade.php index d3ba81b3cf7e3..d106c21a88826 100644 --- a/mod/folder/db/upgrade.php +++ b/mod/folder/db/upgrade.php @@ -49,9 +49,6 @@ function xmldb_folder_upgrade($oldversion) { $dbman = $DB->get_manager(); // Loads ddl manager and xmldb classes. - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/forum/db/upgrade.php b/mod/forum/db/upgrade.php index 37a6b3bcbc617..0d4a5d4fd220c 100644 --- a/mod/forum/db/upgrade.php +++ b/mod/forum/db/upgrade.php @@ -47,24 +47,6 @@ function xmldb_forum_upgrade($oldversion) { $dbman = $DB->get_manager(); // Loads ddl manager and xmldb classes. - if ($oldversion < 2016091200) { - - // Define field lockdiscussionafter to be added to forum. - $table = new xmldb_table('forum'); - $field = new xmldb_field('lockdiscussionafter', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, null, '0', 'displaywordcount'); - - // Conditionally launch add field lockdiscussionafter. - if (!$dbman->field_exists($table, $field)) { - $dbman->add_field($table, $field); - } - - // Forum savepoint reached. - upgrade_mod_savepoint(true, 2016091200, 'forum'); - } - - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/glossary/db/upgrade.php b/mod/glossary/db/upgrade.php index 86ea0a1917792..748a79aac22bd 100644 --- a/mod/glossary/db/upgrade.php +++ b/mod/glossary/db/upgrade.php @@ -22,9 +22,6 @@ function xmldb_glossary_upgrade($oldversion) { global $CFG, $DB; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/imscp/db/upgrade.php b/mod/imscp/db/upgrade.php index 671cee42f1e33..ac32ec4dc80c1 100644 --- a/mod/imscp/db/upgrade.php +++ b/mod/imscp/db/upgrade.php @@ -31,9 +31,6 @@ function xmldb_imscp_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/label/db/upgrade.php b/mod/label/db/upgrade.php index f16a2d9add105..7212edc246f30 100644 --- a/mod/label/db/upgrade.php +++ b/mod/label/db/upgrade.php @@ -47,9 +47,6 @@ function xmldb_label_upgrade($oldversion) { global $CFG, $DB; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/lesson/db/upgrade.php b/mod/lesson/db/upgrade.php index 16657f5d3efde..a3b5ce356368a 100644 --- a/mod/lesson/db/upgrade.php +++ b/mod/lesson/db/upgrade.php @@ -54,9 +54,6 @@ function xmldb_lesson_upgrade($oldversion) { $dbman = $DB->get_manager(); - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - if ($oldversion < 2016120515) { // Define new fields to be added to lesson. $table = new xmldb_table('lesson'); diff --git a/mod/lti/db/upgrade.php b/mod/lti/db/upgrade.php index d8b961af7632f..f77a66186ddfa 100644 --- a/mod/lti/db/upgrade.php +++ b/mod/lti/db/upgrade.php @@ -61,24 +61,6 @@ function xmldb_lti_upgrade($oldversion) { global $CFG, $DB; - $dbman = $DB->get_manager(); - - if ($oldversion < 2016052301) { - - // Changing type of field value on table lti_types_config to text. - $table = new xmldb_table('lti_types_config'); - $field = new xmldb_field('value', XMLDB_TYPE_TEXT, null, null, XMLDB_NOTNULL, null, null, 'name'); - - // Launch change of type for field value. - $dbman->change_field_type($table, $field); - - // Lti savepoint reached. - upgrade_mod_savepoint(true, 2016052301, 'lti'); - } - - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/page/db/upgrade.php b/mod/page/db/upgrade.php index 368f0b8151548..a284b2ed6bcfe 100644 --- a/mod/page/db/upgrade.php +++ b/mod/page/db/upgrade.php @@ -47,9 +47,6 @@ function xmldb_page_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/quiz/db/upgrade.php b/mod/quiz/db/upgrade.php index 82e2f0fad814e..fea86fb4e916f 100644 --- a/mod/quiz/db/upgrade.php +++ b/mod/quiz/db/upgrade.php @@ -33,61 +33,6 @@ function xmldb_quiz_upgrade($oldversion) { $dbman = $DB->get_manager(); - if ($oldversion < 2016092000) { - // Define new fields to be added to quiz. - $table = new xmldb_table('quiz'); - - $field = new xmldb_field('allowofflineattempts', XMLDB_TYPE_INTEGER, '1', null, null, null, 0, 'completionpass'); - // Conditionally launch add field allowofflineattempts. - if (!$dbman->field_exists($table, $field)) { - $dbman->add_field($table, $field); - } - // Quiz savepoint reached. - upgrade_mod_savepoint(true, 2016092000, 'quiz'); - } - - if ($oldversion < 2016092001) { - // New field for quiz_attemps. - $table = new xmldb_table('quiz_attempts'); - - $field = new xmldb_field('timemodifiedoffline', XMLDB_TYPE_INTEGER, '10', null, XMLDB_NOTNULL, null, 0, 'timemodified'); - // Conditionally launch add field timemodifiedoffline. - if (!$dbman->field_exists($table, $field)) { - $dbman->add_field($table, $field); - } - - // Quiz savepoint reached. - upgrade_mod_savepoint(true, 2016092001, 'quiz'); - } - - if ($oldversion < 2016100300) { - // Find quizzes with the combination of require passing grade and grade to pass 0. - $gradeitems = $DB->get_records_sql(" - SELECT gi.id, gi.itemnumber, cm.id AS cmid - FROM {quiz} q - INNER JOIN {course_modules} cm ON q.id = cm.instance - INNER JOIN {grade_items} gi ON q.id = gi.iteminstance - INNER JOIN {modules} m ON m.id = cm.module - WHERE q.completionpass = 1 - AND gi.gradepass = 0 - AND cm.completiongradeitemnumber IS NULL - AND gi.itemmodule = m.name - AND gi.itemtype = ? - AND m.name = ?", array('mod', 'quiz')); - - foreach ($gradeitems as $gradeitem) { - $DB->execute("UPDATE {course_modules} - SET completiongradeitemnumber = :itemnumber - WHERE id = :cmid", - array('itemnumber' => $gradeitem->itemnumber, 'cmid' => $gradeitem->cmid)); - } - // Quiz savepoint reached. - upgrade_mod_savepoint(true, 2016100300, 'quiz'); - } - - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/quiz/report/overview/db/upgrade.php b/mod/quiz/report/overview/db/upgrade.php index e1fbfc3d21cab..13ca01a3ad4b1 100644 --- a/mod/quiz/report/overview/db/upgrade.php +++ b/mod/quiz/report/overview/db/upgrade.php @@ -33,9 +33,6 @@ function xmldb_quiz_overview_upgrade($oldversion) { $dbman = $DB->get_manager(); - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/quiz/report/statistics/db/upgrade.php b/mod/quiz/report/statistics/db/upgrade.php index 2a5c64e389529..a4c0d3fa2e824 100644 --- a/mod/quiz/report/statistics/db/upgrade.php +++ b/mod/quiz/report/statistics/db/upgrade.php @@ -30,16 +30,6 @@ function xmldb_quiz_statistics_upgrade($oldversion) { global $DB; - if ($oldversion < 2016100500) { - // Clear the quiz_statistics table - it is only a cache table anyway. - // This will force re-calculation. - $DB->delete_records('quiz_statistics'); - upgrade_plugin_savepoint(true, 2016100500, 'quiz', 'statistics'); - } - - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/resource/db/upgrade.php b/mod/resource/db/upgrade.php index c2dd1ecea5b74..85b16c1ee7423 100644 --- a/mod/resource/db/upgrade.php +++ b/mod/resource/db/upgrade.php @@ -47,9 +47,6 @@ function xmldb_resource_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/scorm/db/upgrade.php b/mod/scorm/db/upgrade.php index 0ac2aa1c75414..bc4788313f7a0 100644 --- a/mod/scorm/db/upgrade.php +++ b/mod/scorm/db/upgrade.php @@ -34,21 +34,6 @@ function xmldb_scorm_upgrade($oldversion) { $dbman = $DB->get_manager(); - // MDL-44712 improve multi-sco activity completion. - if ($oldversion < 2016080900) { - $table = new xmldb_table('scorm'); - - $field = new xmldb_field('completionstatusallscos', XMLDB_TYPE_INTEGER, '1', null, null, null, null, 'completionscorerequired'); - if (!$dbman->field_exists($table, $field)) { - $dbman->add_field($table, $field); - } - - upgrade_mod_savepoint(true, 2016080900, 'scorm'); - } - - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/survey/db/upgrade.php b/mod/survey/db/upgrade.php index 5ca506e1ee773..4a008999f4a28 100644 --- a/mod/survey/db/upgrade.php +++ b/mod/survey/db/upgrade.php @@ -22,27 +22,7 @@ defined('MOODLE_INTERNAL') || die(); function xmldb_survey_upgrade($oldversion) { - global $DB; - - $dbman = $DB->get_manager(); // Loads ddl manager and xmldb classes. - - if ($oldversion < 2016061400) { - - // Define field completionsubmit to be added to survey. - $table = new xmldb_table('survey'); - $field = new xmldb_field('completionsubmit', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '0', 'questions'); - - // Conditionally launch add field completionsubmit. - if (!$dbman->field_exists($table, $field)) { - $dbman->add_field($table, $field); - } - - // Survey savepoint reached. - upgrade_mod_savepoint(true, 2016061400, 'survey'); - } - - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. + global $CFG; // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/url/db/upgrade.php b/mod/url/db/upgrade.php index 640cead9c7cf7..3065e640010c3 100644 --- a/mod/url/db/upgrade.php +++ b/mod/url/db/upgrade.php @@ -47,9 +47,6 @@ function xmldb_url_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/wiki/db/upgrade.php b/mod/wiki/db/upgrade.php index a8b6ab0e726ee..5b179a96d3ff0 100644 --- a/mod/wiki/db/upgrade.php +++ b/mod/wiki/db/upgrade.php @@ -40,9 +40,6 @@ function xmldb_wiki_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/workshop/db/upgrade.php b/mod/workshop/db/upgrade.php index 97937038efb10..9acd30f4053b2 100644 --- a/mod/workshop/db/upgrade.php +++ b/mod/workshop/db/upgrade.php @@ -39,9 +39,6 @@ function xmldb_workshop_upgrade($oldversion) { $dbman = $DB->get_manager(); - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/workshop/form/accumulative/db/upgrade.php b/mod/workshop/form/accumulative/db/upgrade.php index 60f7de52d45d7..c5cb7bb941390 100644 --- a/mod/workshop/form/accumulative/db/upgrade.php +++ b/mod/workshop/form/accumulative/db/upgrade.php @@ -33,9 +33,6 @@ function xmldb_workshopform_accumulative_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/workshop/form/comments/db/upgrade.php b/mod/workshop/form/comments/db/upgrade.php index 652add1dbaadf..79b166b2f09fb 100644 --- a/mod/workshop/form/comments/db/upgrade.php +++ b/mod/workshop/form/comments/db/upgrade.php @@ -33,9 +33,6 @@ function xmldb_workshopform_comments_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/workshop/form/numerrors/db/upgrade.php b/mod/workshop/form/numerrors/db/upgrade.php index f7993c3febb7c..9d53ee94518e4 100644 --- a/mod/workshop/form/numerrors/db/upgrade.php +++ b/mod/workshop/form/numerrors/db/upgrade.php @@ -33,9 +33,6 @@ function xmldb_workshopform_numerrors_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/mod/workshop/form/rubric/db/upgrade.php b/mod/workshop/form/rubric/db/upgrade.php index cd134416f4f93..d40d5e58e5075 100644 --- a/mod/workshop/form/rubric/db/upgrade.php +++ b/mod/workshop/form/rubric/db/upgrade.php @@ -33,9 +33,6 @@ function xmldb_workshopform_rubric_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/portfolio/boxnet/db/upgrade.php b/portfolio/boxnet/db/upgrade.php index 1dc7483bba2cc..0d8fc59152d5d 100644 --- a/portfolio/boxnet/db/upgrade.php +++ b/portfolio/boxnet/db/upgrade.php @@ -33,9 +33,6 @@ function xmldb_portfolio_boxnet_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/portfolio/googledocs/db/upgrade.php b/portfolio/googledocs/db/upgrade.php index 6e1d3db492c00..2f957c1f58e9f 100644 --- a/portfolio/googledocs/db/upgrade.php +++ b/portfolio/googledocs/db/upgrade.php @@ -23,9 +23,6 @@ function xmldb_portfolio_googledocs_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/portfolio/picasa/db/upgrade.php b/portfolio/picasa/db/upgrade.php index d1ea866b88fde..f745e0f4bf0d8 100644 --- a/portfolio/picasa/db/upgrade.php +++ b/portfolio/picasa/db/upgrade.php @@ -23,9 +23,6 @@ function xmldb_portfolio_picasa_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/question/behaviour/manualgraded/db/upgrade.php b/question/behaviour/manualgraded/db/upgrade.php index 358138a970614..45f5cd010851f 100644 --- a/question/behaviour/manualgraded/db/upgrade.php +++ b/question/behaviour/manualgraded/db/upgrade.php @@ -30,9 +30,6 @@ function xmldb_qbehaviour_manualgraded_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/question/type/calculated/db/upgrade.php b/question/type/calculated/db/upgrade.php index c6d4267a8c3f0..a639b0045d93c 100644 --- a/question/type/calculated/db/upgrade.php +++ b/question/type/calculated/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_qtype_calculated_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/question/type/ddmarker/db/upgrade.php b/question/type/ddmarker/db/upgrade.php index 010b62441f88a..160f0f2f7843a 100644 --- a/question/type/ddmarker/db/upgrade.php +++ b/question/type/ddmarker/db/upgrade.php @@ -33,9 +33,6 @@ function xmldb_qtype_ddmarker_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/question/type/essay/db/upgrade.php b/question/type/essay/db/upgrade.php index 873f93906bd31..93acbb48e3177 100644 --- a/question/type/essay/db/upgrade.php +++ b/question/type/essay/db/upgrade.php @@ -34,9 +34,6 @@ function xmldb_qtype_essay_upgrade($oldversion) { $dbman = $DB->get_manager(); - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/question/type/match/db/upgrade.php b/question/type/match/db/upgrade.php index 0483680ef1229..1dd18fc90bf3c 100644 --- a/question/type/match/db/upgrade.php +++ b/question/type/match/db/upgrade.php @@ -31,9 +31,6 @@ function xmldb_qtype_match_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/question/type/multianswer/db/upgrade.php b/question/type/multianswer/db/upgrade.php index caa3b68de3914..e0bd450329f7f 100644 --- a/question/type/multianswer/db/upgrade.php +++ b/question/type/multianswer/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_qtype_multianswer_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/question/type/multichoice/db/upgrade.php b/question/type/multichoice/db/upgrade.php index fcf0be989cce5..b2dc15b9e3a7b 100644 --- a/question/type/multichoice/db/upgrade.php +++ b/question/type/multichoice/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_qtype_multichoice_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/question/type/numerical/db/upgrade.php b/question/type/numerical/db/upgrade.php index acca38d471d0d..e303c1df9682a 100644 --- a/question/type/numerical/db/upgrade.php +++ b/question/type/numerical/db/upgrade.php @@ -33,6 +33,12 @@ function xmldb_qtype_numerical_upgrade($oldversion) { global $CFG, $DB; $dbman = $DB->get_manager(); + // Automatically generated Moodle v3.3.0 release upgrade line. + // Put any upgrade step following this. + + // Automatically generated Moodle v3.4.0 release upgrade line. + // Put any upgrade step following this. + if ($oldversion < 2017121000) { // Changing length of field multiplier on table question_numerical_units to 38. @@ -46,15 +52,6 @@ function xmldb_qtype_numerical_upgrade($oldversion) { upgrade_plugin_savepoint(true, 2017121000, 'qtype', 'numerical'); } - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - - // Automatically generated Moodle v3.3.0 release upgrade line. - // Put any upgrade step following this. - - // Automatically generated Moodle v3.4.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.5.0 release upgrade line. // Put any upgrade step following this. diff --git a/question/type/random/db/upgrade.php b/question/type/random/db/upgrade.php index 658cd345684a8..cb50b671aece4 100644 --- a/question/type/random/db/upgrade.php +++ b/question/type/random/db/upgrade.php @@ -31,9 +31,6 @@ function xmldb_qtype_random_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/question/type/randomsamatch/db/upgrade.php b/question/type/randomsamatch/db/upgrade.php index 3acd3e623d1e9..c8471b4ba3047 100644 --- a/question/type/randomsamatch/db/upgrade.php +++ b/question/type/randomsamatch/db/upgrade.php @@ -31,9 +31,6 @@ function xmldb_qtype_randomsamatch_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/question/type/shortanswer/db/upgrade.php b/question/type/shortanswer/db/upgrade.php index 413fb48ae7343..63031fe218d6d 100644 --- a/question/type/shortanswer/db/upgrade.php +++ b/question/type/shortanswer/db/upgrade.php @@ -32,9 +32,6 @@ function xmldb_qtype_shortanswer_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/repository/boxnet/db/upgrade.php b/repository/boxnet/db/upgrade.php index fab31f5135180..41d21266c1b6c 100644 --- a/repository/boxnet/db/upgrade.php +++ b/repository/boxnet/db/upgrade.php @@ -33,9 +33,6 @@ function xmldb_repository_boxnet_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/repository/dropbox/db/upgrade.php b/repository/dropbox/db/upgrade.php index 0177d3a6dfa41..73aaf9406b63f 100644 --- a/repository/dropbox/db/upgrade.php +++ b/repository/dropbox/db/upgrade.php @@ -23,13 +23,6 @@ function xmldb_repository_dropbox_upgrade($oldversion) { global $CFG; - if ($oldversion < 2016091300) { - unset_config('legacyapi', 'dropbox'); - upgrade_plugin_savepoint(true, 2016091300, 'repository', 'dropbox'); - } - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/repository/googledocs/db/upgrade.php b/repository/googledocs/db/upgrade.php index dfe5f26d698ed..3266380f01619 100644 --- a/repository/googledocs/db/upgrade.php +++ b/repository/googledocs/db/upgrade.php @@ -23,9 +23,6 @@ function xmldb_repository_googledocs_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - if ($oldversion < 2017011100) { // Set default import formats from Google. set_config('documentformat', 'rtf', 'googledocs'); diff --git a/repository/picasa/db/upgrade.php b/repository/picasa/db/upgrade.php index 1f375189fba79..3ec6125321449 100644 --- a/repository/picasa/db/upgrade.php +++ b/repository/picasa/db/upgrade.php @@ -23,9 +23,6 @@ function xmldb_repository_picasa_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this. diff --git a/theme/more/db/upgrade.php b/theme/more/db/upgrade.php index 8c39b5bb898d2..1573e64c2ee50 100644 --- a/theme/more/db/upgrade.php +++ b/theme/more/db/upgrade.php @@ -33,9 +33,6 @@ function xmldb_theme_more_upgrade($oldversion) { global $CFG; - // Automatically generated Moodle v3.2.0 release upgrade line. - // Put any upgrade step following this. - // Automatically generated Moodle v3.3.0 release upgrade line. // Put any upgrade step following this.