|
@@ 1757-1768 (lines=12) @@
|
| 1754 |
|
|
| 1755 |
|
/** @var $relations \eZ\Publish\API\Repository\Values\Content\Relation[] */ |
| 1756 |
|
$relations = array(); |
| 1757 |
|
foreach ($spiRelations as $spiRelation) { |
| 1758 |
|
$destinationContentInfo = $this->internalLoadContentInfo($spiRelation->destinationContentId); |
| 1759 |
|
if (!$this->repository->canUser('content', 'read', $destinationContentInfo)) { |
| 1760 |
|
continue; |
| 1761 |
|
} |
| 1762 |
|
|
| 1763 |
|
$relations[] = $this->domainMapper->buildRelationDomainObject( |
| 1764 |
|
$spiRelation, |
| 1765 |
|
$contentInfo, |
| 1766 |
|
$destinationContentInfo |
| 1767 |
|
); |
| 1768 |
|
} |
| 1769 |
|
|
| 1770 |
|
return $relations; |
| 1771 |
|
} |
|
@@ 1795-1806 (lines=12) @@
|
| 1792 |
|
); |
| 1793 |
|
|
| 1794 |
|
$returnArray = array(); |
| 1795 |
|
foreach ($spiRelations as $spiRelation) { |
| 1796 |
|
$sourceContentInfo = $this->internalLoadContentInfo($spiRelation->sourceContentId); |
| 1797 |
|
if (!$this->repository->canUser('content', 'read', $sourceContentInfo)) { |
| 1798 |
|
continue; |
| 1799 |
|
} |
| 1800 |
|
|
| 1801 |
|
$returnArray[] = $this->domainMapper->buildRelationDomainObject( |
| 1802 |
|
$spiRelation, |
| 1803 |
|
$sourceContentInfo, |
| 1804 |
|
$contentInfo |
| 1805 |
|
); |
| 1806 |
|
} |
| 1807 |
|
|
| 1808 |
|
return $returnArray; |
| 1809 |
|
} |