More globals rewritten, see ticket #100
[mailer.git] / inc / libs / user_functions.php
index 8e913f21ae3d51c9a9c228e4ff060f5f35951c4b..f5103384843691161a1fae922459644670daabbe 100644 (file)
@@ -384,14 +384,14 @@ function USER_DO_LOGIN ($uid, $passwd) {
                        list($status) = SQL_FETCHROW($result);
 
                        // Create an error code from given status
                        list($status) = SQL_FETCHROW($result);
 
                        // Create an error code from given status
-                       $ERROR = GEN_ERROR_CODE_FROM_ACCOUNT_STATUS($status);
+                       $errorCode = GEN_ERROR_CODE_FROM_ACCOUNT_STATUS($status);
                } else {
                        // ID not found!
                } else {
                        // ID not found!
-                       $ERROR = getCode('WRONG_ID');
+                       $errorCode = getCode('WRONG_ID');
                }
 
                // Construct URL
                }
 
                // Construct URL
-               $URL = "modules.php?module=index&what=login&login=".$ERROR;
+               $URL = "modules.php?module=index&what=login&login=".$errorCode;
        } else {
                // ID not found!
                $URL = "modules.php?module=index&what=login&login=".getCode('WRONG_ID');
        } else {
                // ID not found!
                $URL = "modules.php?module=index&what=login&login=".getCode('WRONG_ID');
@@ -407,7 +407,7 @@ function USER_DO_NEW_PASSWORD ($email, $uid) {
        if (!empty($email)) $email = str_replace("{DOT}", '.', $email);
 
        // Init result and error
        if (!empty($email)) $email = str_replace("{DOT}", '.', $email);
 
        // Init result and error
-       $ERROR = "";
+       $errorCode = "";
        $result = false;
 
        // Probe userid/nickname
        $result = false;
 
        // Probe userid/nickname
@@ -426,7 +426,7 @@ function USER_DO_NEW_PASSWORD ($email, $uid) {
        } else {
                // Userid not set!
                DEBUG_LOG(__FUNCTION__, __LINE__, "Userid is not set! BUG!");
        } else {
                // Userid not set!
                DEBUG_LOG(__FUNCTION__, __LINE__, "Userid is not set! BUG!");
-               $ERROR = getCode('WRONG_ID');
+               $errorCode = getCode('WRONG_ID');
        }
 
        // Any entry found?
        }
 
        // Any entry found?
@@ -450,10 +450,10 @@ function USER_DO_NEW_PASSWORD ($email, $uid) {
                        LOAD_TEMPLATE("admin_settings_saved", false, getMessage('GUEST_NEW_PASSWORD_SEND'));
                } else {
                        // Account is locked or unconfirmed
                        LOAD_TEMPLATE("admin_settings_saved", false, getMessage('GUEST_NEW_PASSWORD_SEND'));
                } else {
                        // Account is locked or unconfirmed
-                       $ERROR = GEN_ERROR_CODE_FROM_ACCOUNT_STATUS($status);
+                       $errorCode = GEN_ERROR_CODE_FROM_ACCOUNT_STATUS($status);
 
                        // Load URL
 
                        // Load URL
-                       LOAD_URL("modules.php?module=index&what=login&login=".$ERROR);
+                       LOAD_URL("modules.php?module=index&what=login&login=".$errorCode);
                }
        } else {
                // ID or email is wrong
                }
        } else {
                // ID or email is wrong
@@ -461,7 +461,7 @@ function USER_DO_NEW_PASSWORD ($email, $uid) {
        }
 
        // Return the error code
        }
 
        // Return the error code
-       return $ERROR;
+       return $errorCode;
 }
 
 // [EOF]
 }
 
 // [EOF]