Skip to content

Commit

Permalink
Fixing whitespace in CakeSchema
Browse files Browse the repository at this point in the history
  • Loading branch information
lorenzo committed Jul 15, 2011
1 parent 7596fcf commit 11f4d1c
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions lib/Cake/Model/CakeSchema.php
Expand Up @@ -224,24 +224,23 @@ public function read($options = array()) {
$models = App::objects('Model');
}
}

if (is_array($models)) {
foreach ($models as $model) {
$importModel = $model;
$plugin = null;

if ($model == 'AppModel') {
continue;
}

if (isset($this->plugin)) {
if ($model == $this->plugin . 'AppModel') {
continue;
}
$importModel = $model;
$plugin = $this->plugin . '.';
}

App::uses($importModel, $plugin . 'Model');
if (!class_exists($importModel)) {
continue;
Expand Down Expand Up @@ -295,7 +294,7 @@ public function read($options = array()) {
}
}
}

if (!empty($currentTables)) {
foreach ($currentTables as $table) {
if ($prefix) {
Expand Down Expand Up @@ -329,7 +328,6 @@ public function read($options = array()) {

ksort($tables);
return compact('name', 'tables');

}

/**
Expand Down

0 comments on commit 11f4d1c

Please sign in to comment.