diff options
author | Andreas Gohr <andi@splitbrain.org> | 2013-08-22 01:12:47 -0700 |
---|---|---|
committer | Andreas Gohr <andi@splitbrain.org> | 2013-08-22 01:12:47 -0700 |
commit | 5a3aabcff0e246c29f47c1dd65301712cd553308 (patch) | |
tree | 2245231ac0dcbeea7084a751f89699e3307133f2 /inc/auth.php | |
parent | ef0239a32ff44792b95819fe52398f3fc0dc4fae (diff) | |
parent | 7ef8e99fe605c5da36ab6b5d317b22fcd17f665b (diff) | |
download | rpg-5a3aabcff0e246c29f47c1dd65301712cd553308.tar.gz rpg-5a3aabcff0e246c29f47c1dd65301712cd553308.tar.bz2 |
Merge pull request #311 from mperry2/scopeindent
Fix CodeSniffer violations
Diffstat (limited to 'inc/auth.php')
-rw-r--r-- | inc/auth.php | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/inc/auth.php b/inc/auth.php index 696456cfc..8be270bfc 100644 --- a/inc/auth.php +++ b/inc/auth.php @@ -48,15 +48,15 @@ function auth_setup() { // try to load auth backend from plugins foreach ($plugin_controller->getList('auth') as $plugin) { - if ($conf['authtype'] === $plugin) { - $auth = $plugin_controller->load('auth', $plugin); - break; - } elseif ('auth' . $conf['authtype'] === $plugin) { - // matches old auth backends (pre-Weatherwax) - $auth = $plugin_controller->load('auth', $plugin); - msg('Your authtype setting is deprecated. You must set $conf[\'authtype\'] = "auth' . $conf['authtype'] . '"' - . ' in your configuration (see <a href="https://www.dokuwiki.org/auth">Authentication Backends</a>)',-1,'','',MSG_ADMINS_ONLY); - } + if ($conf['authtype'] === $plugin) { + $auth = $plugin_controller->load('auth', $plugin); + break; + } elseif ('auth' . $conf['authtype'] === $plugin) { + // matches old auth backends (pre-Weatherwax) + $auth = $plugin_controller->load('auth', $plugin); + msg('Your authtype setting is deprecated. You must set $conf[\'authtype\'] = "auth' . $conf['authtype'] . '"' + . ' in your configuration (see <a href="https://www.dokuwiki.org/auth">Authentication Backends</a>)',-1,'','',MSG_ADMINS_ONLY); + } } if(!isset($auth) || !$auth){ @@ -65,10 +65,10 @@ function auth_setup() { } if ($auth->success == false) { - // degrade to unauthenticated user - unset($auth); - auth_logoff(); - msg($lang['authtempfail'], -1); + // degrade to unauthenticated user + unset($auth); + auth_logoff(); + msg($lang['authtempfail'], -1); return false; } |