20after4 has submitted this change and it was merged. Change subject: Redirect HEAD to correct default branch ......................................................................
Redirect HEAD to correct default branch For example the link would be https://phabricator.wikimedia.org/diffusion/MCSN/browse/ instead of https://phabricator.wikimedia.org/diffusion/MCSN/browse/HEAD/ Change-Id: I8ccd94690be9e678a16a1c587e8f4fce1d696a88 --- M GerritProjectController.php 1 file changed, 1 insertion(+), 0 deletions(-) Approvals: 20after4: Looks good to me, approved jenkins-bot: Verified diff --git a/GerritProjectController.php b/GerritProjectController.php index 4716fe3..bf6d5c9 100644 --- a/GerritProjectController.php +++ b/GerritProjectController.php @@ -1324,6 +1324,7 @@ // get rid of refs/heads prefix $branch = str_replace('refs/heads', '', $branch); $branch = trim($branch, '/'); + $branch = str_replace('HEAD', ''); // double encode any forward slashes in ref. $branch = str_replace('/', '%252F', $branch); -- To view, visit https://gerrit.wikimedia.org/r/260023 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I8ccd94690be9e678a16a1c587e8f4fce1d696a88 Gerrit-PatchSet: 2 Gerrit-Project: phabricator/extensions Gerrit-Branch: master Gerrit-Owner: Paladox <[email protected]> Gerrit-Reviewer: 20after4 <[email protected]> Gerrit-Reviewer: Chad <[email protected]> Gerrit-Reviewer: Paladox <[email protected]> Gerrit-Reviewer: jenkins-bot <> _______________________________________________ MediaWiki-commits mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
