1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-10 00:42:41 +01:00

Fix links after D1921

Test Plan:
Search for some symbol. Click on the result. Verify that there is not // in URL.
Click on the link from generated exception.
View history in Diffusion, click on Browse.

Reviewers: epriestley

Reviewed By: epriestley

CC: aran, epriestley

Differential Revision: https://secure.phabricator.com/D1979
This commit is contained in:
vrana 2012-03-21 13:07:51 -07:00
parent ccc258fa85
commit 5c5ead2666
4 changed files with 6 additions and 6 deletions

View file

@ -1,6 +1,6 @@
{ {
"name" : "Phabricator", "name" : "Phabricator",
"src_base" : "https://secure.phabricator.com/diffusion/P/browse/origin:master", "src_base" : "https://secure.phabricator.com/diffusion/P/browse/master",
"groups" : { "groups" : {
"intro" : "Introduction", "intro" : "Introduction",
"config" : "Configuration", "config" : "Configuration",
@ -30,4 +30,3 @@
["DivinerXHPEngine", {}] ["DivinerXHPEngine", {}]
] ]
} }

View file

@ -523,11 +523,11 @@ class AphrontDefaultApplicationConfiguration
$browse = array( $browse = array(
'arcanist' => 'arcanist' =>
$host.'/diffusion/ARC/browse/origin:master/src/', $host.'/diffusion/ARC/browse/master/src/',
'phutil' => 'phutil' =>
$host.'/diffusion/PHU/browse/origin:master/src/', $host.'/diffusion/PHU/browse/master/src/',
'phabricator' => 'phabricator' =>
$host.'/diffusion/P/browse/origin:master/src/', $host.'/diffusion/P/browse/master/src/',
); );
$rows = array(); $rows = array();

View file

@ -326,6 +326,7 @@ abstract class DiffusionRequest {
} }
if (strlen($path)) { if (strlen($path)) {
$path = ltrim($path, '/');
$path = str_replace(array(';', '$'), array(';;', '$$'), $path); $path = str_replace(array(';', '$'), array(';;', '$$'), $path);
$path = phutil_escape_uri($path); $path = phutil_escape_uri($path);
} }

View file

@ -74,7 +74,7 @@ abstract class DiffusionView extends AphrontView {
final public function linkBrowse($path, array $details = array()) { final public function linkBrowse($path, array $details = array()) {
$href = $this->getDiffusionRequest()->generateURI( $href = $this->getDiffusionRequest()->generateURI(
array( $details + array(
'action' => 'browse', 'action' => 'browse',
'path' => $path, 'path' => $path,
)); ));