Skip to content
Permalink
Browse files

(Fixing upgrade script) Only try to disable lams if it is installed

Author: Andrew Walbran <andrew.walbran@catalyst.net.nz>
  • Loading branch information...
martinlanghoff
martinlanghoff committed Feb 28, 2007
1 parent abb6fc0 commit 171d8232498ac29e5c026971ce919870d9703193
Showing with 2 additions and 2 deletions.
  1. +2 −2 lib/db/upgrade.php
@@ -50,8 +50,8 @@ function xmldb_main_upgrade($oldversion=0) {
}
}
if ($oldversion < 2006101001) { /// Disable the LAMS module by default
if (!count_records('lams')) {
if ($oldversion < 2006101001) { /// Disable the LAMS module by default (if it is installed)
if (count_records('modules', 'name', 'lams') && !count_records('lams')) {
set_field('modules', 'visible', 0, 'name', 'lams'); // Disable it by default
}
}

0 comments on commit 171d823

Please sign in to comment.
You can’t perform that action at this time.