From 0b3e4c816ebd11bde090d4d5baa68d94801067c3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tim=20D=C3=BCsterhus?= Date: Wed, 8 May 2013 20:30:39 +0200 Subject: [PATCH] Disable message pruning if CHAT_LOG_ARCHIVETIME is set to -1 --- file/lib/data/message/MessageAction.class.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/file/lib/data/message/MessageAction.class.php b/file/lib/data/message/MessageAction.class.php index dff95f8..5432d33 100644 --- a/file/lib/data/message/MessageAction.class.php +++ b/file/lib/data/message/MessageAction.class.php @@ -26,6 +26,8 @@ class MessageAction extends \wcf\data\AbstractDatabaseObjectAction { * @return integer Number of deleted messages. */ public function prune() { + if (CHAT_LOG_ARCHIVETIME == -1) return 0; + $sql = "SELECT ".call_user_func(array($this->className, 'getDatabaseTableIndexName'))." FROM