// Fixed upgrade bug (wrong db function used)

This commit is contained in:
dMetzger
2012-08-08 16:38:26 +00:00
parent 72d1bd6e92
commit 5cedf07170
@@ -27,8 +27,7 @@
function drop_image_type_non_unique_index()
{
$index = Db::getInstance()->executeS('SHOW index FROM `'._DB_PREFIX_.'image_type` where column_name = "name" and non_unique=1');
// do not use pSql, this function is not defined
Db::getInstance()->execute('ALTER TABLE `'._DB_PREFIX_.'image_type` DROP INDEX "'.$index.'"');
$index = Db::getInstance()->getValue('SHOW index FROM `'._DB_PREFIX_.'image_type` where column_name = "name" and non_unique=1');
Db::getInstance()->execute('ALTER TABLE `'._DB_PREFIX_.'image_type` DROP INDEX "'.pSQL($index).'"');
}