Merge pull request #2854 from nextcloud/2fa-redirect-url

Set redirect_url on 2FA challenge page
This commit is contained in:
Robin Appelman 2016-12-28 16:28:08 +01:00 committed by GitHub
commit 75747c5d2f
2 changed files with 2 additions and 0 deletions

View File

@ -128,6 +128,7 @@ class TwoFactorChallengeController extends Controller {
'provider' => $provider,
'backupProvider' => $backupProvider,
'logout_attribute' => $this->getLogoutAttribute(),
'redirect_url' => $redirect_url,
'template' => $tmpl->fetchPage(),
];
return new TemplateResponse($this->appName, 'twofactorshowchallenge', $data, 'guest');

View File

@ -143,6 +143,7 @@ class TwoFactorChallengeControllerTest extends TestCase {
'backupProvider' => $backupProvider,
'logout_attribute' => 'logoutAttribute',
'template' => '<html/>',
'redirect_url' => '/re/dir/ect/url',
], 'guest');
$this->assertEquals($expected, $this->controller->showChallenge('myprovider', '/re/dir/ect/url'));