Code cleanup and some fixes
This commit is contained in:
@@ -69,9 +69,11 @@ if (ThisFileIsRequested(__FILE__)) {
|
||||
ReturnJSONError($Err_RDP_InvalidArgs, "only allowed symbols are: " . $Config["registration"]["allowed_syms"]);
|
||||
}
|
||||
|
||||
// Check if login already exists
|
||||
if (User_LoginExist($login))
|
||||
ReturnJSONError($Err_RDP_InvalidArgs, "login already exists");
|
||||
|
||||
// Create account
|
||||
$result = User_Create($login, $password, $email, $invite);
|
||||
ReturnJSONData(["success" => $result]);
|
||||
} else { // Not enough arguments
|
||||
|
||||
Reference in New Issue
Block a user