Tidied up user-detection code

This commit is contained in:
FractalParadigm 2025-03-15 07:45:07 -04:00
parent 81a3ac3969
commit f13d2ed907

View File

@ -18,13 +18,12 @@ try { // Try opening the SQL database connection
// Get results from the USERS table
$results = $sqlGetUserList->fetch();
$userExists = false;
// Check if user exists
if (isset($results)) {
if (mb_strtolower($_GET["username"]) != mb_strtolower($results["username"])) {
$userExists = false;
} else {
if (mb_strtolower($_GET["username"]) == mb_strtolower($results["username"])) {
$userExists = true;
}
}
}