mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-27 01:02:42 +01:00
Fix symbol URI generation to include default branch name for relevant repositories
Summary: We need to build a request in order to pick up an appropriate default branch name, instead of using the raw static generator. Test Plan: Clicked a symbol link, got /master/path/blahblah Reviewers: vrana, btrahan Reviewed By: vrana CC: aran, epriestley Differential Revision: https://secure.phabricator.com/D1982
This commit is contained in:
parent
5eb922fdb4
commit
620e936cba
2 changed files with 5 additions and 3 deletions
|
@ -145,7 +145,6 @@ final class DiffusionSymbolController extends DiffusionController {
|
|||
'',
|
||||
'',
|
||||
'',
|
||||
'n'
|
||||
));
|
||||
$table->setNoDataString(
|
||||
"No matching symbol could be found in any indexed project.");
|
||||
|
|
|
@ -45,10 +45,13 @@ final class PhabricatorRepositorySymbol extends PhabricatorRepositoryDAO {
|
|||
}
|
||||
|
||||
public function getURI() {
|
||||
return DiffusionRequest::generateDiffusionURI(
|
||||
$request = DiffusionRequest::newFromDictionary(
|
||||
array(
|
||||
'repository' => $this->getRepository(),
|
||||
));
|
||||
return $request->generateURI(
|
||||
array(
|
||||
'action' => 'browse',
|
||||
'callsign' => $this->getRepository()->getCallsign(),
|
||||
'path' => $this->getPath(),
|
||||
'line' => $this->getLineNumber(),
|
||||
));
|
||||
|
|
Loading…
Reference in a new issue