Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Nitpicks
  • Loading branch information
lorenzo committed Mar 27, 2014
1 parent eba9fb3 commit 42c3732
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
3 changes: 1 addition & 2 deletions src/ORM/Association/BelongsToMany.php
Expand Up @@ -257,8 +257,7 @@ public function transformRow($row, $joined) {
$row[$this->target()->alias()][$this->_junctionProperty] = $row[$alias];
unset($row[$alias]);
}
$row = $this->_transformRow($row, $joined);
return $row;
return $this->_transformRow($row, $joined);
}

/**
Expand Down
5 changes: 3 additions & 2 deletions src/ORM/Association/ExternalAssociationTrait.php
Expand Up @@ -99,8 +99,9 @@ public function transformRow($row, $joined) {
$sourceAlias = $this->source()->alias();
$targetAlias = $this->target()->alias();

if (isset($row[$this->_name . '___collection_'])) {
$values = $row[$this->_name . '___collection_'];
$collectionAlias = $this->_name . '___collection_';
if (isset($row[$collectionAlias])) {
$values = $row[$collectionAlias];
} else {
$values = $row[$this->_name];
}
Expand Down

0 comments on commit 42c3732

Please sign in to comment.