mirror of
https://we.phorge.it/source/phorge.git
synced 2025-02-20 10:48:40 +01:00
When a user tries to regsiter while logged in, just send them home
Summary: This error message is pointless and dead-ends logged-in users needlessly if they're sent to the register page by documentation or Advanced Enterprise Sales Funnels. Test Plan: Visited `/auth/register/` while logged in, was sent home. Reviewers: chad Reviewed By: chad Differential Revision: https://secure.phabricator.com/D15739
This commit is contained in:
parent
025b243e27
commit
eef2172161
1 changed files with 1 additions and 1 deletions
|
@ -12,7 +12,7 @@ final class PhabricatorAuthRegisterController
|
||||||
$account_key = $request->getURIData('akey');
|
$account_key = $request->getURIData('akey');
|
||||||
|
|
||||||
if ($request->getUser()->isLoggedIn()) {
|
if ($request->getUser()->isLoggedIn()) {
|
||||||
return $this->renderError(pht('You are already logged in.'));
|
return id(new AphrontRedirectResponse())->setURI('/');
|
||||||
}
|
}
|
||||||
|
|
||||||
$is_setup = false;
|
$is_setup = false;
|
||||||
|
|
Loading…
Add table
Reference in a new issue