diff options
Diffstat (limited to 'backend/auth.php')
-rw-r--r-- | backend/auth.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/backend/auth.php b/backend/auth.php index cf646d8..36ddc86 100644 --- a/backend/auth.php +++ b/backend/auth.php @@ -25,7 +25,7 @@ elseif (!isset($wrkarr["password"]) || trim($wrkarr["password"]) == ""): die('{ "status": "password was not provided.\ncould not attempt to log in." }'); else: - $query = $pdo->prepare("SELECT name, password FROM users WHERE name LIKE ?"); + $query = $pdo->prepare("SELECT name, password, token, team FROM users WHERE name LIKE ?"); $query -> execute([$wrkarr["name"]]); $found = $query->fetch(PDO::FETCH_ASSOC); if ($found): @@ -34,7 +34,7 @@ else: die('{ "status": "wrong password." }'); else: - die('{ "status": "success" }'); + die("{ \"status\": \"success\", \"token\": \"$found[token]\", \"team\": \"$found[team]\" }"); endif; |