forked from leftypol/leftypol
bans.php: refactor to expose the moratorium on ban deletion from the database.
Also fixes the 'purge_bans' configuration for non-cache deployments.
This commit is contained in:
parent
4b03672f77
commit
d69eebb1d3
4 changed files with 8 additions and 8 deletions
|
@ -7,7 +7,7 @@ require dirname(__FILE__) . '/inc/cli.php';
|
|||
|
||||
echo "Clearing expired bans...";
|
||||
$start = microtime(true);
|
||||
$deleted_count = Bans::purge($config['require_ban_view']);
|
||||
$deleted_count = Bans::purge($config['require_ban_view'], $config['purge_bans']);
|
||||
$delta = microtime(true) - $start;
|
||||
echo "Deleted $deleted_count expired bans in $delta seconds!";
|
||||
modLog("Deleted expired bans in {$delta}s with tools/maintenance.php");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue