From bc27d1eae4fecaf5bf8a84480b20d578a538e325 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Lorenzo=20Rodr=C3=ADguez=20Urdaneta?= Date: Thu, 15 Jul 2010 23:17:13 -0430 Subject: [PATCH] Returning only booleans in Model::__isset() and removing return by reference in Model::getDataSource() --- cake/libs/model/model.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/cake/libs/model/model.php b/cake/libs/model/model.php index 18ca886b0..5a0b9330f 100644 --- a/cake/libs/model/model.php +++ b/cake/libs/model/model.php @@ -555,7 +555,8 @@ class Model extends Object { $this->{$name}->primaryKey = $this->hasAndBelongsToMany[$assocKey]['foreignKey']; } } - return $this->{$name}; + + return true; } /** @@ -2813,7 +2814,7 @@ class Model extends Object { * * @return object A DataSource object */ - public function &getDataSource() { + public function getDataSource() { static $configured = false; if (!$configured && $this->useTable !== false) { $configured = true;