summaryrefslogtreecommitdiff
path: root/app/Controller/User.php
diff options
context:
space:
mode:
Diffstat (limited to 'app/Controller/User.php')
-rw-r--r--app/Controller/User.php10
1 files changed, 6 insertions, 4 deletions
diff --git a/app/Controller/User.php b/app/Controller/User.php
index c94c2c88..cc7464e6 100644
--- a/app/Controller/User.php
+++ b/app/Controller/User.php
@@ -34,12 +34,11 @@ class User extends Base
$this->response->redirect('?controller=app');
}
- $redirect_query = $this->request->getStringParam('redirect_query');
$this->response->html($this->template->layout('user_login', array(
'errors' => array(),
'values' => array(),
'no_layout' => true,
- 'redirect_query' => $redirect_query,
+ 'redirect_query' => $this->request->getStringParam('redirect_query'),
'title' => t('Login')
)));
}
@@ -56,9 +55,10 @@ class User extends Base
list($valid, $errors) = $this->authentication->validateForm($values);
if ($valid) {
- if ($redirect_query != "") {
+ if ($redirect_query !== '') {
$this->response->redirect('?'.$redirect_query);
- } else {
+ }
+ else {
$this->response->redirect('?controller=board');
}
}
@@ -420,6 +420,7 @@ class User extends Base
'errors' => array('login' => t('Google authentication failed')),
'values' => array(),
'no_layout' => true,
+ 'redirect_query' => '',
'title' => t('Login')
)));
}
@@ -481,6 +482,7 @@ class User extends Base
'errors' => array('login' => t('GitHub authentication failed')),
'values' => array(),
'no_layout' => true,
+ 'redirect_query' => '',
'title' => t('Login')
)));
}