Skip to content
Snippets Groups Projects
Commit 27058a05 authored by Michael Hamann's avatar Michael Hamann
Browse files

Fix and add type declarations for the auth system

parent e4207845
No related branches found
No related tags found
No related merge requests found
...@@ -40,7 +40,7 @@ function auth_setup() { ...@@ -40,7 +40,7 @@ function auth_setup() {
global $INPUT; global $INPUT;
global $AUTH_ACL; global $AUTH_ACL;
global $lang; global $lang;
global $config_cascade; /* @var Doku_Plugin_Controller $plugin_controller */
global $plugin_controller; global $plugin_controller;
$AUTH_ACL = array(); $AUTH_ACL = array();
...@@ -207,7 +207,7 @@ function auth_login($user, $pass, $sticky = false, $silent = false) { ...@@ -207,7 +207,7 @@ function auth_login($user, $pass, $sticky = false, $silent = false) {
global $USERINFO; global $USERINFO;
global $conf; global $conf;
global $lang; global $lang;
/* @var auth_basic $auth */ /* @var DokuWiki_Auth_Plugin $auth */
global $auth; global $auth;
$sticky ? $sticky = true : $sticky = false; //sanity check $sticky ? $sticky = true : $sticky = false; //sanity check
...@@ -361,7 +361,7 @@ function auth_cookiesalt($addsession = false) { ...@@ -361,7 +361,7 @@ function auth_cookiesalt($addsession = false) {
function auth_logoff($keepbc = false) { function auth_logoff($keepbc = false) {
global $conf; global $conf;
global $USERINFO; global $USERINFO;
/* @var auth_basic $auth */ /* @var DokuWiki_Auth_Plugin $auth */
global $auth; global $auth;
// make sure the session is writable (it usually is) // make sure the session is writable (it usually is)
...@@ -407,7 +407,7 @@ function auth_logoff($keepbc = false) { ...@@ -407,7 +407,7 @@ function auth_logoff($keepbc = false) {
function auth_ismanager($user = null, $groups = null, $adminonly = false) { function auth_ismanager($user = null, $groups = null, $adminonly = false) {
global $conf; global $conf;
global $USERINFO; global $USERINFO;
/* @var auth_basic $auth */ /* @var DokuWiki_Auth_Plugin $auth */
global $auth; global $auth;
if(!$auth) return false; if(!$auth) return false;
...@@ -460,7 +460,7 @@ function auth_isadmin($user = null, $groups = null) { ...@@ -460,7 +460,7 @@ function auth_isadmin($user = null, $groups = null) {
* @return bool true for membership acknowledged * @return bool true for membership acknowledged
*/ */
function auth_isMember($memberlist, $user, array $groups) { function auth_isMember($memberlist, $user, array $groups) {
/* @var auth_basic $auth */ /* @var DokuWiki_Auth_Plugin $auth */
global $auth; global $auth;
if(!$auth) return false; if(!$auth) return false;
...@@ -526,7 +526,7 @@ function auth_quickaclcheck($id) { ...@@ -526,7 +526,7 @@ function auth_quickaclcheck($id) {
function auth_aclcheck($id, $user, $groups) { function auth_aclcheck($id, $user, $groups) {
global $conf; global $conf;
global $AUTH_ACL; global $AUTH_ACL;
/* @var auth_basic $auth */ /* @var DokuWiki_Auth_Plugin $auth */
global $auth; global $auth;
// if no ACL is used always return upload rights // if no ACL is used always return upload rights
...@@ -725,7 +725,7 @@ function auth_pwgen($foruser = '') { ...@@ -725,7 +725,7 @@ function auth_pwgen($foruser = '') {
*/ */
function auth_sendPassword($user, $password) { function auth_sendPassword($user, $password) {
global $lang; global $lang;
/* @var auth_basic $auth */ /* @var DokuWiki_Auth_Plugin $auth */
global $auth; global $auth;
if(!$auth) return false; if(!$auth) return false;
...@@ -759,7 +759,7 @@ function auth_sendPassword($user, $password) { ...@@ -759,7 +759,7 @@ function auth_sendPassword($user, $password) {
function register() { function register() {
global $lang; global $lang;
global $conf; global $conf;
/* @var auth_basic $auth */ /* @var DokuWiki_Auth_Plugin $auth */
global $auth; global $auth;
global $INPUT; global $INPUT;
...@@ -828,7 +828,7 @@ function register() { ...@@ -828,7 +828,7 @@ function register() {
function updateprofile() { function updateprofile() {
global $conf; global $conf;
global $lang; global $lang;
/* @var auth_basic $auth */ /* @var DokuWiki_Auth_Plugin $auth */
global $auth; global $auth;
/* @var Input $INPUT */ /* @var Input $INPUT */
global $INPUT; global $INPUT;
...@@ -918,7 +918,7 @@ function updateprofile() { ...@@ -918,7 +918,7 @@ function updateprofile() {
function act_resendpwd() { function act_resendpwd() {
global $lang; global $lang;
global $conf; global $conf;
/* @var auth_basic $auth */ /* @var DokuWiki_Auth_Plugin $auth */
global $auth; global $auth;
/* @var Input $INPUT */ /* @var Input $INPUT */
global $INPUT; global $INPUT;
...@@ -1084,7 +1084,7 @@ function auth_verifyPassword($clear, $crypt) { ...@@ -1084,7 +1084,7 @@ function auth_verifyPassword($clear, $crypt) {
*/ */
function auth_setCookie($user, $pass, $sticky) { function auth_setCookie($user, $pass, $sticky) {
global $conf; global $conf;
/* @var auth_basic $auth */ /* @var DokuWiki_Auth_Plugin $auth */
global $auth; global $auth;
global $USERINFO; global $USERINFO;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment