diff options
author | Lukas Reschke <lukas@statuscode.ch> | 2016-08-31 19:46:38 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-08-31 19:46:38 +0200 |
commit | 2685129184472a308a3ba7730207816151b0ffd7 (patch) | |
tree | 60129965ee6469d2405cedccf6f04132f77b84e1 /core | |
parent | 5fe25fa64832aa349628afe62336921aa7e3e6a0 (diff) | |
parent | 8e5c4c91faba6747682339ed7af95a1227d2f1b4 (diff) | |
download | nextcloud-server-2685129184472a308a3ba7730207816151b0ffd7.tar.gz nextcloud-server-2685129184472a308a3ba7730207816151b0ffd7.zip |
Merge pull request #1188 from nextcloud/2fa-redirect-default-app
redirect to default app after solving the 2FA challenge
Diffstat (limited to 'core')
-rw-r--r-- | core/Controller/TwoFactorChallengeController.php | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/core/Controller/TwoFactorChallengeController.php b/core/Controller/TwoFactorChallengeController.php index c19cf523279..48dea062812 100644 --- a/core/Controller/TwoFactorChallengeController.php +++ b/core/Controller/TwoFactorChallengeController.php @@ -24,6 +24,8 @@ namespace OC\Core\Controller; use OC\Authentication\TwoFactorAuth\Manager; +use OC_User; +use OC_Util; use OCP\AppFramework\Controller; use OCP\AppFramework\Http\RedirectResponse; use OCP\AppFramework\Http\TemplateResponse; @@ -67,7 +69,7 @@ class TwoFactorChallengeController extends Controller { * @return string */ protected function getLogoutAttribute() { - return \OC_User::getLogoutAttribute(); + return OC_User::getLogoutAttribute(); } /** @@ -143,7 +145,7 @@ class TwoFactorChallengeController extends Controller { if (!is_null($redirect_url)) { return new RedirectResponse($this->urlGenerator->getAbsoluteURL(urldecode($redirect_url))); } - return new RedirectResponse($this->urlGenerator->linkToRoute('files.view.index')); + return new RedirectResponse(OC_Util::getDefaultPageUrl()); } $this->session->set('two_factor_auth_error', true); |