From: skodak Date: Mon, 20 Apr 2009 18:59:50 +0000 (+0000) Subject: MDL-18910 normalised module intro and introformat X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=83afecc04b67dab3233bf67205de3cbe3e9f3382;p=moodle.git MDL-18910 normalised module intro and introformat --- diff --git a/mod/feedback/db/upgrade.php b/mod/feedback/db/upgrade.php index ba7e0e84de..e46d9c8b77 100644 --- a/mod/feedback/db/upgrade.php +++ b/mod/feedback/db/upgrade.php @@ -270,8 +270,10 @@ function xmldb_feedback_upgrade($oldversion) { $table = new xmldb_table('feedback'); $field = new xmldb_field('introformat', XMLDB_TYPE_INTEGER, '2', XMLDB_UNSIGNED, XMLDB_NOTNULL, null, null, null, '0', 'intro'); - /// Launch add field introformat - $dbman->add_field($table, $field); + /// Conditionally launch add field introformat + if (!$dbman->field_exists($table, $field)) { + $dbman->add_field($table, $field); + } /// feedback savepoint reached upgrade_mod_savepoint($result, 2009042001, 'feedback');