From: skodak Date: Fri, 2 May 2008 09:42:43 +0000 (+0000) Subject: MDL-14605 removing stats upgrade stuff X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=0b51c247f039752024cec928bda5b05c1cc57466;p=moodle.git MDL-14605 removing stats upgrade stuff --- diff --git a/admin/cliupgrade.php b/admin/cliupgrade.php index 1751a0ed1d..a47a0acd2d 100644 --- a/admin/cliupgrade.php +++ b/admin/cliupgrade.php @@ -882,7 +882,6 @@ if ( file_exists(dirname(dirname(__FILE__)) . '/config.php')) { if ($status) { // Install the roles system. moodle_install_roles(); - set_config('statsrolesupgraded',time()); // Write default settings unconditionally (i.e. even if a setting is already set, overwrite it) // (this should only have any effect during initial install). diff --git a/admin/index.php b/admin/index.php index 1ed262cb73..60cb459538 100644 --- a/admin/index.php +++ b/admin/index.php @@ -193,7 +193,6 @@ // Install the roles system. moodle_install_roles(); - set_config('statsrolesupgraded',time()); // install core event handlers events_update_definition(); diff --git a/lib/db/upgrade.php b/lib/db/upgrade.php index dbae6e799b..f89268996c 100644 --- a/lib/db/upgrade.php +++ b/lib/db/upgrade.php @@ -55,6 +55,12 @@ function xmldb_main_upgrade($oldversion=0) { upgrade_main_savepoint($result, 2008050100); } + if ($result && $oldversion < 2008050200) { + // remove unused config options + unset_config('statsrolesupgraded'); + upgrade_main_savepoint($result, 2008050200); + } + return $result; } diff --git a/version.php b/version.php index bf8199dba8..9178825dfd 100644 --- a/version.php +++ b/version.php @@ -6,7 +6,7 @@ // This is compared against the values stored in the database to determine // whether upgrades should be performed (see lib/db/*.php) - $version = 2008050100; // YYYYMMDD = date of the last version bump + $version = 2008050200; // YYYYMMDD = date of the last version bump // XX = daily increments $release = '2.0 dev (Build: 20080502)'; // Human-friendly version name