]> git.mxchange.org Git - core.git/blobdiff - framework/main/classes/filter/validator/class_UserNameValidatorFilter.php
Rewrite continued:
[core.git] / framework / main / classes / filter / validator / class_UserNameValidatorFilter.php
index dd0ea3262feb2412ad2be0b0efa4d4a8e64edb94..fafe694261048d6939ac1f24d4bf859ff9614311 100644 (file)
@@ -72,7 +72,7 @@ class UserNameValidatorFilter extends BaseFilter implements Filterable {
                // Is the username set?
                if (is_null($userName)) {
                        // Not found in form so stop the filtering process
                // Is the username set?
                if (is_null($userName)) {
                        // Not found in form so stop the filtering process
-                       $requestInstance->requestIsValid(FALSE);
+                       $requestInstance->requestIsValid(false);
 
                        // Add a message to the response
                        $responseInstance->addFatalMessage('username_unset');
 
                        // Add a message to the response
                        $responseInstance->addFatalMessage('username_unset');
@@ -81,7 +81,7 @@ class UserNameValidatorFilter extends BaseFilter implements Filterable {
                        throw new FilterChainException($this, self::EXCEPTION_FILTER_CHAIN_INTERCEPTED);
                } elseif (empty($userName)) {
                        // Empty field!
                        throw new FilterChainException($this, self::EXCEPTION_FILTER_CHAIN_INTERCEPTED);
                } elseif (empty($userName)) {
                        // Empty field!
-                       $requestInstance->requestIsValid(FALSE);
+                       $requestInstance->requestIsValid(false);
 
                        // Add a message to the response
                        $responseInstance->addFatalMessage('username_empty');
 
                        // Add a message to the response
                        $responseInstance->addFatalMessage('username_empty');
@@ -90,7 +90,7 @@ class UserNameValidatorFilter extends BaseFilter implements Filterable {
                        throw new FilterChainException($this, self::EXCEPTION_FILTER_CHAIN_INTERCEPTED);
                } elseif ($this->ifUserNameIsTaken($userName)) {
                        // Username is already taken
                        throw new FilterChainException($this, self::EXCEPTION_FILTER_CHAIN_INTERCEPTED);
                } elseif ($this->ifUserNameIsTaken($userName)) {
                        // Username is already taken
-                       $requestInstance->requestIsValid(FALSE);
+                       $requestInstance->requestIsValid(false);
 
                        // Add a message to the response
                        $responseInstance->addFatalMessage('username_taken');
 
                        // Add a message to the response
                        $responseInstance->addFatalMessage('username_taken');
@@ -108,7 +108,7 @@ class UserNameValidatorFilter extends BaseFilter implements Filterable {
         */
        private function ifUserNameIsTaken ($userName) {
                // Default is already taken
         */
        private function ifUserNameIsTaken ($userName) {
                // Default is already taken
-               $alreadyTaken = TRUE;
+               $alreadyTaken = true;
 
                // Initialize instance
                $userInstance = NULL;
 
                // Initialize instance
                $userInstance = NULL;
@@ -135,9 +135,9 @@ class UserNameValidatorFilter extends BaseFilter implements Filterable {
                }
 
                // Does the username exist?
                }
 
                // Does the username exist?
-               if ((is_null($userInstance)) || ($userInstance->ifUsernameExists() === FALSE)) {
+               if ((is_null($userInstance)) || ($userInstance->ifUsernameExists() === false)) {
                        // This username is still available
                        // This username is still available
-                       $alreadyTaken = FALSE;
+                       $alreadyTaken = false;
                } // END - if
 
                // Return the result
                } // END - if
 
                // Return the result