diff --git a/files/lib/data/message/MessageEditor.class.php b/files/lib/data/message/MessageEditor.class.php index 3551389..4bf77f1 100644 --- a/files/lib/data/message/MessageEditor.class.php +++ b/files/lib/data/message/MessageEditor.class.php @@ -1,11 +1,11 @@ beginTransaction(); + + $result = parent::deleteAll($messageIDs); + if (!empty($messageIDs)) { + AttachmentHandler::removeAttachments('be.bastelstu.chat.message', $messageIDs); + } + + WCF::getDB()->commitTransaction(); + + return $result; + } }