diff options
author | Frederic Guillot <fred@kanboard.net> | 2015-05-24 16:02:25 -0400 |
---|---|---|
committer | Frederic Guillot <fred@kanboard.net> | 2015-05-24 16:02:25 -0400 |
commit | eeac2329baab1fdae7cbf6c707ed2ffd8beb4c1b (patch) | |
tree | 511c2fe47f8fbb1ea90e59e7a7a7f5e3530aa9ed /app/Controller/Twofactor.php | |
parent | 65e9e5d1bed9f88ecfd43eb2c1e780a7c22c151f (diff) |
Helpers refactoring
Diffstat (limited to 'app/Controller/Twofactor.php')
-rw-r--r-- | app/Controller/Twofactor.php | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/app/Controller/Twofactor.php b/app/Controller/Twofactor.php index c21729ba..a8b0351f 100644 --- a/app/Controller/Twofactor.php +++ b/app/Controller/Twofactor.php @@ -76,7 +76,7 @@ class Twofactor extends User $_SESSION['user']['twofactor_activated'] = false; $this->session->flash(t('User updated successfully.')); - $this->response->redirect($this->helper->url('twofactor', 'index', array('user_id' => $user['id']))); + $this->response->redirect($this->helper->url->to('twofactor', 'index', array('user_id' => $user['id']))); } /** @@ -99,7 +99,7 @@ class Twofactor extends User $this->session->flashError(t('The two factor authentication code is not valid.')); } - $this->response->redirect($this->helper->url('twofactor', 'index', array('user_id' => $user['id']))); + $this->response->redirect($this->helper->url->to('twofactor', 'index', array('user_id' => $user['id']))); } /** @@ -118,11 +118,11 @@ class Twofactor extends User if (! empty($values['code']) && $otp->checkTotp(Base32::decode($user['twofactor_secret']), $values['code'])) { $this->session['2fa_validated'] = true; $this->session->flash(t('The two factor authentication code is valid.')); - $this->response->redirect($this->helper->url('app', 'index')); + $this->response->redirect($this->helper->url->to('app', 'index')); } else { $this->session->flashError(t('The two factor authentication code is not valid.')); - $this->response->redirect($this->helper->url('twofactor', 'code')); + $this->response->redirect($this->helper->url->to('twofactor', 'code')); } } @@ -157,7 +157,7 @@ class Twofactor extends User 'twofactor_secret' => '', )); - $this->response->redirect($this->helper->url('user', 'show', array('user_id' => $user['id']))); + $this->response->redirect($this->helper->url->to('user', 'show', array('user_id' => $user['id']))); } $this->response->html($this->layout('twofactor/disable', array( |