Permalink
Browse files

MDL-16879 - check & fix mandatory mnet_host records and orphan users.…

… Bump version to next int one.
  • Loading branch information...
1 parent 0a5bf56 commit 767904d06c4c8057629db5ea456153584c4ace74 stronk7 committed May 11, 2009
Showing with 11 additions and 1 deletion.
  1. +10 −0 lib/db/upgrade.php
  2. +1 −1 version.php
View
@@ -3159,6 +3159,16 @@ function xmldb_main_upgrade($oldversion=0) {
upgrade_main_savepoint($result, 2007101546.06);
}
+ if ($result && $oldversion < 2007101547) {
+ // Let's check the status of mandatory mnet_host records, fixing them
+ // and moving "orphan" users to default localhost record. MDL-16879
+ notify('Fixing mnet records, this may take a while...', 'notifysuccess');
+ $db->debug = false; // Can output too much. Disabling
+ upgrade_fix_incorrect_mnethostids();
+ $db->debug = true; // Restoring debug level
+ upgrade_main_savepoint($result, 2007101547);
+ }
+
return $result;
}
View
@@ -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 = 2007101546.06; // YYYYMMDD = date of the 1.9 branch (don't change)
+ $version = 2007101547; // YYYYMMDD = date of the 1.9 branch (don't change)
// X = release number 1.9.[0,1,2,3,4,5...]
// Y.YY = micro-increments between releases

0 comments on commit 767904d

Please sign in to comment.