Fixing issue loading plugin models when uses == false.

This commit is contained in:
mark_story 2010-12-04 23:49:00 -05:00
parent 9dd78c7dc1
commit d202ea643d

View file

@ -476,9 +476,10 @@ class Controller extends Object {
} else {
$id = $this->passedArgs['0'];
}
$plugin = $this->plugin ? $this->plugin . '.' : null;
if ($this->uses === false) {
$this->loadModel($this->modelClass, $id);
$this->loadModel($plugin . $this->modelClass, $id);
} elseif ($this->uses) {
$uses = is_array($this->uses) ? $this->uses : array($this->uses);
list($plugin, $modelClassName) = pluginSplit($uses[0]);