[fix] bad currentBan report
This commit is contained in:
parent
dfa164d699
commit
50ca517960
|
@ -1,6 +1,6 @@
|
|||
<?php
|
||||
function getCurrentBan($db, $sortBy = 'ban_date, ban_time', $order = 'DESC') {
|
||||
$sql = mysqli_query($db, "SELECT id,service,ip,ban_date,ban_time,country,countryCode FROM bans WHERE bans.ip NOT IN ( SELECT unbans.ip FROM unbans WHERE bans.ip=unbans.ip) ORDER BY $sortBy $order");
|
||||
$sql = mysqli_query($db, "SELECT id,service,ip,ban_date,ban_time,country,countryCode FROM bans WHERE bans.id NOT IN ( SELECT unbans.id FROM unbans WHERE bans.id=unbans.id) ORDER BY $sortBy $order");
|
||||
while ($rows = mysqli_fetch_assoc($sql)) {
|
||||
$currentBan[] = $rows;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue