Browse Source

Merge pull request #264 from cajoy/upstream

Fixed issue with getting Object component
tags/2.0.0-beta
Qiang Xue 12 years ago
parent
commit
6431019ae3
  1. 2
      yii/base/Module.php

2
yii/base/Module.php

@ -449,7 +449,7 @@ abstract class Module extends Component
public function getComponent($id, $load = true)
{
if (isset($this->_components[$id])) {
if ($this->_components[$id] instanceof Component) {
if ($this->_components[$id] instanceof Object) {
return $this->_components[$id];
} elseif ($load) {
Yii::trace("Loading component: $id", __METHOD__);

Loading…
Cancel
Save