1
0
mirror of https://github.com/vichan-devel/vichan.git synced 2025-01-22 11:23:45 +01:00

7.4 compatibility

This commit is contained in:
Lorenzo Yario 2024-12-22 14:59:12 -06:00 committed by GitHub
parent c4cd4d3c12
commit 40571f2001
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -37,7 +37,7 @@ class Bans {
}
}
static private function findSingleAutoGc(string $ip, int $ban_id, bool $require_ban_view): array|null {
static private function findSingleAutoGc(string $ip, int $ban_id, bool $require_ban_view) {
// Use OR in the query to also garbage collect bans.
$query = prepare(
'SELECT ``bans``.* FROM ``bans``
@ -70,7 +70,7 @@ class Bans {
return $found_ban;
}
static private function findSingleNoGc(int $ban_id): array|null {
static private function findSingleNoGc(int $ban_id) {
$query = prepare(
'SELECT ``bans``.* FROM ``bans``
WHERE ``bans``.id = :id
@ -268,7 +268,7 @@ class Bans {
return [$ipstart, $ipend];
}
static public function findSingle(string $ip, int $ban_id, bool $require_ban_view, bool $auto_gc): array|null {
static public function findSingle(string $ip, int $ban_id, bool $require_ban_view, bool $auto_gc) {
if ($auto_gc) {
return self::findSingleAutoGc($ip, $ban_id, $require_ban_view);
} else {