From d77659f6f8cc535f57669df59680913d6baf5e96 Mon Sep 17 00:00:00 2001 From: Michael Save Date: Thu, 19 Apr 2012 01:19:10 +1000 Subject: [PATCH] Bugfix: did not purge all antispam inputs --- inc/functions.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/inc/functions.php b/inc/functions.php index 1d10c09a..da22a094 100644 --- a/inc/functions.php +++ b/inc/functions.php @@ -860,6 +860,11 @@ function deletePost($id, $error_if_doesnt_exist=true, $rebuild_after=true) { if (!$post['thread']) { // Delete thread HTML page file_unlink($board['dir'] . $config['dir']['res'] . sprintf($config['file_page'], $post['id'])); + + $antispam_query = prepare('DELETE FROM `antispam` WHERE `board` = :board AND `thread` = :thread'); + $antispam_query->bindValue(':board', $board['uri']); + $antispam_query->bindValue(':thread', $post['id']); + $antispam_query->execute() or error(db_error($antispam_query)); } elseif ($query->rowCount() == 1) { // Rebuild thread $rebuild = &$post['thread'];