mirror of
https://github.com/islehorse/HISP.git
synced 2025-04-20 19:59:15 +12:00
Fix the bug where every user is an admin
This commit is contained in:
parent
964a4e879c
commit
0e571700fa
3 changed files with 6 additions and 2 deletions
|
@ -272,7 +272,7 @@ function get_admin(int $userid)
|
|||
$stmt->bind_param("i", $userid);
|
||||
$stmt->execute();
|
||||
$result = $stmt->get_result();
|
||||
return $result->fetch_row()[0];
|
||||
return $result->fetch_row()[0] === "YES";
|
||||
|
||||
}
|
||||
|
||||
|
@ -285,7 +285,7 @@ function get_mod(int $userid)
|
|||
$stmt->bind_param("i", $userid);
|
||||
$stmt->execute();
|
||||
$result = $stmt->get_result();
|
||||
return $result->fetch_row()[0];
|
||||
return $result->fetch_row()[0] === "YES";
|
||||
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue