Skip to content

Commit

Permalink
Fixing failing test caused by merge with 1.2
Browse files Browse the repository at this point in the history
  • Loading branch information
markstory committed Jan 16, 2010
1 parent 1acc4c8 commit 826dbc4
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions cake/libs/model/cake_schema.php
Expand Up @@ -486,10 +486,13 @@ function compare($old, $new = null) {
if (isset($old[$table]['indexes']) && isset($new[$table]['indexes'])) {
$diff = $this->_compareIndexes($new[$table]['indexes'], $old[$table]['indexes']);
if ($diff) {
if (isset($tables[$table]['drop']['indexes']) && isset($diff['drop'])) {
if (!isset($tables[$table])) {
$tables[$table] = array();
}
if (isset($diff['drop'])) {
$tables[$table]['drop']['indexes'] = $diff['drop'];
}
if (isset($tables[$table]['add']['indexes']) && isset($diff['add'])) {
if ($diff && isset($diff['add'])) {
$tables[$table]['add']['indexes'] = $diff['add'];
}
}
Expand Down

0 comments on commit 826dbc4

Please sign in to comment.