mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-10 17:02:41 +01:00
Clean up a PhutilURI "alter()" callsite in Diffusion blame
Summary: See <https://discourse.phabricator-community.org/t/exception-when-viewing-previous-revision-from-blame/2454/2>. Test Plan: Viewed blame, clicked "Skip Past This Commit". Got jumped to the right place instead of a URI exception. Reviewers: amckinley Reviewed By: amckinley Differential Revision: https://secure.phabricator.com/D20222
This commit is contained in:
parent
620047bcfe
commit
4cc556b576
1 changed files with 11 additions and 2 deletions
|
@ -709,8 +709,17 @@ final class DiffusionBrowseController extends DiffusionController {
|
|||
'path' => $path,
|
||||
));
|
||||
|
||||
$before_uri = $before_uri->alter('renamed', $renamed);
|
||||
$before_uri = $before_uri->alter('follow', $follow);
|
||||
if ($renamed === null) {
|
||||
$before_uri->removeQueryParam('renamed');
|
||||
} else {
|
||||
$before_uri->replaceQueryParam('renamed', $renamed);
|
||||
}
|
||||
|
||||
if ($follow === null) {
|
||||
$before_uri->removeQueryParam('follow');
|
||||
} else {
|
||||
$before_uri->replaceQueryParam('follow', $follow);
|
||||
}
|
||||
|
||||
return id(new AphrontRedirectResponse())->setURI($before_uri);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue