mirror of
https://gitlab.com/ruany/litebans-php.git
synced 2025-05-24 00:42:43 +00:00
Fix pure IP bans being shown on pager
This commit is contained in:
parent
7fef0ac8f7
commit
cd998e5c82
@ -209,6 +209,7 @@ class Page {
|
|||||||
* @return null|string
|
* @return null|string
|
||||||
*/
|
*/
|
||||||
function get_name($uuid) {
|
function get_name($uuid) {
|
||||||
|
if ($uuid === null || $uuid === "" || strrpos($uuid, "#", -strlen($uuid)) !== false) return null;
|
||||||
if (in_array($uuid, $this->settings->console_aliases)) {
|
if (in_array($uuid, $this->settings->console_aliases)) {
|
||||||
return $this->settings->console_name;
|
return $this->settings->console_name;
|
||||||
}
|
}
|
||||||
@ -383,7 +384,7 @@ class Page {
|
|||||||
$page = $this->name . ".php";
|
$page = $this->name . ".php";
|
||||||
|
|
||||||
if ($total === -1) {
|
if ($total === -1) {
|
||||||
$result = $this->conn->query("SELECT COUNT(*) AS count FROM $table")->fetch(PDO::FETCH_ASSOC);
|
$result = $this->conn->query("SELECT COUNT(*) AS count FROM $table WHERE uuid <> '#offline#' AND uuid IS NOT NULL")->fetch(PDO::FETCH_ASSOC);
|
||||||
$total = $result['count'];
|
$total = $result['count'];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user