diff --git a/file/lib/data/room/RoomAction.class.php b/file/lib/data/room/RoomAction.class.php index ef84c10..1848c28 100644 --- a/file/lib/data/room/RoomAction.class.php +++ b/file/lib/data/room/RoomAction.class.php @@ -27,6 +27,12 @@ class RoomAction extends \wcf\data\AbstractDatabaseObjectAction implements \wcf\ */ protected $permissionsUpdate = array('admin.chat.canEditRoom'); + /** + * Resets cache if any of the listed actions is invoked + * @var array + */ + protected $resetCache = array('create', 'delete', 'toggle', 'update', 'updatePosition', 'prune'); + /** * Fixes create to append new rooms. */ diff --git a/file/lib/data/room/RoomEditor.class.php b/file/lib/data/room/RoomEditor.class.php index 0bb25f5..12fcc9e 100644 --- a/file/lib/data/room/RoomEditor.class.php +++ b/file/lib/data/room/RoomEditor.class.php @@ -50,9 +50,9 @@ public static function deleteAll(array $objectIDs = array()) { $update->execute(array($select->fetchColumn())); } - // The transaction is being committed in parent::deleteAll() - // The beginTransaction() call in there is simply ignored. - return parent::deleteAll($objectIDs); + $return = parent::deleteAll($objectIDs); + WCF::getDB()->commitTransaction(); + return $return; } /**