Differential D15986 Diff 38488 src/applications/diffusion/conduit/DiffusionBranchQueryConduitAPIMethod.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/diffusion/conduit/DiffusionBranchQueryConduitAPIMethod.php
Show First 20 Lines • Show All 50 Lines • ▼ Show 20 Lines | if (strlen($contains)) { | ||||
foreach ($ref_map as $ref => $commit) { | foreach ($ref_map as $ref => $commit) { | ||||
$refs[] = id(new DiffusionRepositoryRef()) | $refs[] = id(new DiffusionRepositoryRef()) | ||||
->setShortName($ref) | ->setShortName($ref) | ||||
->setCommitIdentifier($commit); | ->setCommitIdentifier($commit); | ||||
} | } | ||||
} else { | } else { | ||||
$refs = id(new DiffusionLowLevelGitRefQuery()) | $refs = id(new DiffusionLowLevelGitRefQuery()) | ||||
->setRepository($repository) | ->setRepository($repository) | ||||
->withIsOriginBranch(true) | ->withRefTypes( | ||||
array( | |||||
PhabricatorRepositoryRefCursor::TYPE_BRANCH, | |||||
)) | |||||
->execute(); | ->execute(); | ||||
} | } | ||||
return $this->processBranchRefs($request, $refs); | return $this->processBranchRefs($request, $refs); | ||||
} | } | ||||
protected function getMercurialResult(ConduitAPIRequest $request) { | protected function getMercurialResult(ConduitAPIRequest $request) { | ||||
$drequest = $this->getDiffusionRequest(); | $drequest = $this->getDiffusionRequest(); | ||||
▲ Show 20 Lines • Show All 58 Lines • Show Last 20 Lines |