Browse Source

Fixing return by reference error on the use of ConnectionManager::getDataSource() on a non-existing datasource.

jperras 16 years ago
parent
commit
11365e7a09
1 changed files with 2 additions and 1 deletions
  1. 2 1
      cake/libs/model/connection_manager.php

+ 2 - 1
cake/libs/model/connection_manager.php

@@ -114,7 +114,8 @@ class ConnectionManager extends Object {
 			$_this->_dataSources[$name]->configKeyName = $name;
 		} else {
 			trigger_error(sprintf(__("ConnectionManager::getDataSource - Non-existent data source %s", true), $name), E_USER_ERROR);
-			return null;
+			$null = null;
+			return $null;
 		}
 
 		$return =& $_this->_dataSources[$name];