$index = new xmldb_index('contextid-lowerboundary', XMLDB_INDEX_NOTUNIQUE, array('contextid', 'lowerboundary'));
/// Launch drop index contextid-lowerboundary
- $dbman->drop_index($table, $index);
+ if ($dbman->index_exists($table, $index)) {
+ $dbman->drop_index($table, $index);
+ }
/// Define index contextid-lowerboundary-letter (unique) to be added to grade_letters
$table = new xmldb_table('grade_letters');
if (!$this->index_exists($xmldb_table, $xmldb_intex)) {
throw new ddl_exception('ddlunknownerror', null,
'Index ' . $xmldb_table->getName() . '->' . $xmldb_intex->getName() .
- ' does not exist. Delete skipped');
+ ' does not exist. Drop skipped');
}
if (!$sqlarr = $this->generator->getDropIndexSQL($xmldb_table, $xmldb_intex)) {