From c1c53e3d716dfc9bbf072c627c50873f5599ae27 Mon Sep 17 00:00:00 2001 From: Retro_Guy Date: Tue, 11 Jun 2024 05:28:56 -0700 Subject: [PATCH] Remember to clear history for group if reset. --- Rocksolid_Light/rslight/scripts/maintenance.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Rocksolid_Light/rslight/scripts/maintenance.php b/Rocksolid_Light/rslight/scripts/maintenance.php index d644117..c553e11 100644 --- a/Rocksolid_Light/rslight/scripts/maintenance.php +++ b/Rocksolid_Light/rslight/scripts/maintenance.php @@ -221,6 +221,13 @@ function remove_articles($group) echo "Deleting " . $delme . " from " . $group . "\n"; } + # History + $history_dbh = history_db_open($spooldir . '/history.db3'); + $clear_stmt = $history_dbh->prepare("DELETE FROM history WHERE newsgroup=:group"); + $clear_stmt->bindParam(':group', $group); + $clear_stmt->execute(); + $history_dbh = null; + rename($spooldir . '/' . $group . '-articles.db3', $spooldir . '/' . $group . '-articles.db3-removed'); unlink($spooldir . '/' . $group . '-data.db3'); unlink($spooldir . '/' . $group . '-info.txt');