summaryrefslogtreecommitdiff
path: root/app/Controller/Oauth.php
diff options
context:
space:
mode:
authorFrederic Guillot <fred@kanboard.net>2015-11-15 12:50:33 -0500
committerFrederic Guillot <fred@kanboard.net>2015-11-15 12:50:33 -0500
commita675271ad71b7713d1b33bdba3c51b2b04813229 (patch)
treee54d8a95e16ca521193b9fd5a5eb071aa2910823 /app/Controller/Oauth.php
parent2fc402f6733573627ad25394d109b9f848ef04f6 (diff)
Rewrite of session management
Diffstat (limited to 'app/Controller/Oauth.php')
-rw-r--r--app/Controller/Oauth.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/app/Controller/Oauth.php b/app/Controller/Oauth.php
index 8c701cf7..39546148 100644
--- a/app/Controller/Oauth.php
+++ b/app/Controller/Oauth.php
@@ -51,9 +51,9 @@ class Oauth extends Base
$this->checkCSRFParam();
if ($this->authentication->backend($backend)->unlink($this->userSession->getId())) {
- $this->session->flash(t('Your external account is not linked anymore to your profile.'));
+ $this->flash->success(t('Your external account is not linked anymore to your profile.'));
} else {
- $this->session->flashError(t('Unable to unlink your external account.'));
+ $this->flash->failure(t('Unable to unlink your external account.'));
}
$this->response->redirect($this->helper->url->to('user', 'external', array('user_id' => $this->userSession->getId())));
@@ -99,9 +99,9 @@ class Oauth extends Base
private function link($backend, $profile)
{
if (empty($profile)) {
- $this->session->flashError(t('External authentication failed'));
+ $this->flash->failure(t('External authentication failed'));
} else {
- $this->session->flash(t('Your external account is linked to your profile successfully.'));
+ $this->flash->success(t('Your external account is linked to your profile successfully.'));
$this->authentication->backend($backend)->updateUser($this->userSession->getId(), $profile);
}