Skip to content

Commit

Permalink
Don't detach entities when fetching trees
Browse files Browse the repository at this point in the history
NestedSet should not assume objects are newly fetched from the database.
Thanks to Luka Novsak for finding this.

This reverts commit 72640e2.
  • Loading branch information
Brandon Turner committed Nov 9, 2010
1 parent b4f460f commit c3f72a2
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions lib/DoctrineExtensions/NestedSet/Manager.php
Expand Up @@ -177,12 +177,6 @@ public function fetchBranchAsArray($pk, $depth=null)
return array();
}

// Detach the fetched node as Doctrine uses it instead of the node
// fetched as part of the tree. The node fetched as part of the tree
// may have additional joined classes via base query builder.
$this->getEntityManager()->detach($node);


$qb = $config->getBaseQueryBuilder();
$alias = $config->getQueryBuilderAlias();

Expand Down

0 comments on commit c3f72a2

Please sign in to comment.