-
Bug
-
Resolution: Fixed
-
Major
-
3.1.1
-
None
The migration tries to delete the old key:
'drop_keys' => array(
|
$this->table_prefix . 'search_wordmatch' => array(
|
'unq_mtch',
|
),
|
),
|
tools:
// Remove keys?
|
if (!empty($schema_changes['drop_keys']))
|
{
|
foreach ($schema_changes['drop_keys'] as $table => $indexes)
|
{
|
foreach ($indexes as $index_name)
|
{
|
if (!$this->sql_index_exists($table, $index_name))
|
{
|
continue;
|
}
|
|
$result = $this->sql_index_drop($table, $index_name);
|
...
|
}
|
}
|
}
|
However, sql_index_exists() ignores UNIQUE keys as per doc block:
Check if a specified index exists in table. Does not return PRIMARY KEY and UNIQUE indexes.
Since the key we are trying to delete is a unique key, the function returns false and we skip the drop query (which wouldn't even work on some DB backends?)
So we actually need to implement sql_unique_index_drop()