Changeset View
Changeset View
Standalone View
Standalone View
src/applications/repository/query/PhabricatorRepositoryQuery.php
Show First 20 Lines • Show All 627 Lines • ▼ Show 20 Lines | protected function buildWhereClauseParts(AphrontDatabaseConnection $conn) { | ||||
if ($this->uuids) { | if ($this->uuids) { | ||||
$where[] = qsprintf( | $where[] = qsprintf( | ||||
$conn, | $conn, | ||||
'r.uuid IN (%Ls)', | 'r.uuid IN (%Ls)', | ||||
$this->uuids); | $this->uuids); | ||||
} | } | ||||
if (strlen($this->datasourceQuery)) { | if (phutil_nonempty_string($this->datasourceQuery)) { | ||||
// This handles having "rP" match callsigns starting with "P...". | // This handles having "rP" match callsigns starting with "P...". | ||||
$query = trim($this->datasourceQuery); | $query = trim($this->datasourceQuery); | ||||
if (preg_match('/^r/', $query)) { | if (preg_match('/^r/', $query)) { | ||||
$callsign = substr($query, 1); | $callsign = substr($query, 1); | ||||
} else { | } else { | ||||
$callsign = $query; | $callsign = $query; | ||||
} | } | ||||
$where[] = qsprintf( | $where[] = qsprintf( | ||||
▲ Show 20 Lines • Show All 62 Lines • Show Last 20 Lines |