Commit cb146fb8 authored by njero's avatar njero

The index lookup needs to allow for array("fields" => "name") where the fields list

is a string and not an array
parent bc6ff690
......@@ -104,7 +104,10 @@ class Doctrine_Export_Mysql extends Doctrine_Export
$found = false;
if (isset($options['indexes'])) {
foreach ($options['indexes'] as $definition) {
if (in_array($local, $definition['fields']) && count($definition['fields']) === 1) {
if (is_string($definition['fields'])) {
// Check if index already exists on the column
$found = ($local == $definition['fields']);
} else if (in_array($local, $definition['fields']) && count($definition['fields']) === 1) {
// Index already exists on the column
$found = true;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment