Changeset View
Changeset View
Standalone View
Standalone View
src/applications/diffusion/query/DiffusionCommitQuery.php
Show First 20 Lines • Show All 363 Lines • ▼ Show 20 Lines | if ($this->identifiers !== null) { | ||||
$sql[] = qsprintf( | $sql[] = qsprintf( | ||||
$conn_r, | $conn_r, | ||||
'(commit.commitIdentifier LIKE %> AND '. | '(commit.commitIdentifier LIKE %> AND '. | ||||
'LENGTH(commit.commitIdentifier) = 40)', | 'LENGTH(commit.commitIdentifier) = 40)', | ||||
$identifier); | $identifier); | ||||
} | } | ||||
if ($refs) { | if ($refs) { | ||||
$callsigns = ipull($refs, 'callsign'); | $callsigns = array_unique(ipull($refs, 'callsign')); | ||||
$repos = id(new PhabricatorRepositoryQuery()) | $repos = id(new PhabricatorRepositoryQuery()) | ||||
->setViewer($this->getViewer()) | ->setViewer($this->getViewer()) | ||||
->withIdentifiers($callsigns); | ->withIdentifiers($callsigns); | ||||
$repos->execute(); | $repos->execute(); | ||||
$repos = $repos->getIdentifierMap(); | $repos = $repos->getIdentifierMap(); | ||||
foreach ($refs as $key => $ref) { | foreach ($refs as $key => $ref) { | ||||
▲ Show 20 Lines • Show All 185 Lines • Show Last 20 Lines |