Skip to content

Commit

Permalink
Merge pull request #3481 from okinaka/master
Browse files Browse the repository at this point in the history
Unset $db in DboSource::read().
  • Loading branch information
markstory committed May 13, 2014
2 parents e9ecfe0 + 91cb3dd commit 418c0a7
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/Cake/Model/Datasource/DboSource.php
Expand Up @@ -1140,6 +1140,7 @@ public function read(Model $Model, $queryData = array(), $recursive = null) {
$stack['_joined'] = $joined;

$db->queryAssociation($Model, $LinkModel, $type, $assoc, $assocData, $array, true, $resultSet, $Model->recursive - 1, $stack);
unset($db);

if ($type === 'hasMany' || $type === 'hasAndBelongsToMany') {
$filtered[] = $assoc;
Expand Down

0 comments on commit 418c0a7

Please sign in to comment.