Added missing clean up
authorMarcel Werk <burntime@woltlab.com>
Sat, 16 Feb 2013 14:36:10 +0000 (15:36 +0100)
committerMarcel Werk <burntime@woltlab.com>
Sat, 16 Feb 2013 14:36:10 +0000 (15:36 +0100)
wcfsetup/install/files/lib/system/cronjob/DailyCleanUpCronjob.class.php

index a6ab0b564df6d9f560e78017e59e3144f3a5c632..9590801b5b3592e4a402365eb0034ea4e275a3bd 100644 (file)
@@ -49,6 +49,14 @@ class DailyCleanUpCronjob extends AbstractCronjob {
                        (TIME_NOW - (86400 * 30))
                ));
                
+               // clean up search data
+               $sql = "DELETE FROM     wcf".WCF_N."_search
+                       WHERE           searchTime < ?";
+               $statement = WCF::getDB()->prepareStatement($sql);
+               $statement->execute(array(
+                       (TIME_NOW - 86400)
+               ));
+               
                EventHandler::getInstance()->fireAction($this, 'execute');
        }
 }