Changeset View
Changeset View
Standalone View
Standalone View
src/applications/conpherence/query/ConpherenceThreadQuery.php
Show First 20 Lines • Show All 194 Lines • ▼ Show 20 Lines | foreach ($conpherences as $phid => $conpherence) { | ||||
} | } | ||||
$conpherence->attachHandles($conpherence->getHandles() + $handles); | $conpherence->attachHandles($conpherence->getHandles() + $handles); | ||||
$conpherence->attachTransactions($current_transactions); | $conpherence->attachTransactions($current_transactions); | ||||
} | } | ||||
return $this; | return $this; | ||||
} | } | ||||
private function loadFilePHIDs(array $conpherences) { | private function loadFilePHIDs(array $conpherences) { | ||||
$edge_type = PhabricatorEdgeConfig::TYPE_OBJECT_HAS_FILE; | $edge_type = PhabricatorObjectHasFileEdgeType::EDGECONST; | ||||
$file_edges = id(new PhabricatorEdgeQuery()) | $file_edges = id(new PhabricatorEdgeQuery()) | ||||
->withSourcePHIDs(array_keys($conpherences)) | ->withSourcePHIDs(array_keys($conpherences)) | ||||
->withEdgeTypes(array($edge_type)) | ->withEdgeTypes(array($edge_type)) | ||||
->execute(); | ->execute(); | ||||
foreach ($file_edges as $conpherence_phid => $data) { | foreach ($file_edges as $conpherence_phid => $data) { | ||||
$conpherence = $conpherences[$conpherence_phid]; | $conpherence = $conpherences[$conpherence_phid]; | ||||
$conpherence->attachFilePHIDs(array_keys($data[$edge_type])); | $conpherence->attachFilePHIDs(array_keys($data[$edge_type])); | ||||
} | } | ||||
▲ Show 20 Lines • Show All 83 Lines • Show Last 20 Lines |