From: Marcel Werk Date: Mon, 17 Oct 2016 21:29:02 +0000 (+0200) Subject: Fixed issue in embedded object manager X-Git-Tag: 3.0.0_Beta_3~20 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=3fb7e23aff1d1e1b3124cd48e6479d1bb8578442;p=GitHub%2FWoltLab%2FWCF.git Fixed issue in embedded object manager --- diff --git a/wcfsetup/install/files/lib/system/message/embedded/object/MessageEmbeddedObjectManager.class.php b/wcfsetup/install/files/lib/system/message/embedded/object/MessageEmbeddedObjectManager.class.php index c378588cb7..d464ebcddc 100644 --- a/wcfsetup/install/files/lib/system/message/embedded/object/MessageEmbeddedObjectManager.class.php +++ b/wcfsetup/install/files/lib/system/message/embedded/object/MessageEmbeddedObjectManager.class.php @@ -170,15 +170,12 @@ class MessageEmbeddedObjectManager extends SingletonFactory { $statement->execute($conditionBuilder->getParameters()); $embeddedObjects = []; while ($row = $statement->fetchArray()) { - if (isset($this->embeddedObjects[$row['embeddedObjectTypeID']][$row['embeddedObjectID']])) { - // embedded object already loaded - continue; + if (!isset($this->embeddedObjects[$row['embeddedObjectTypeID']][$row['embeddedObjectID']])) { + // group objects by object type + if (!isset($embeddedObjects[$row['embeddedObjectTypeID']])) $embeddedObjects[$row['embeddedObjectTypeID']] = []; + $embeddedObjects[$row['embeddedObjectTypeID']][] = $row['embeddedObjectID']; } - // group objects by object type - if (!isset($embeddedObjects[$row['embeddedObjectTypeID']])) $embeddedObjects[$row['embeddedObjectTypeID']] = []; - $embeddedObjects[$row['embeddedObjectTypeID']][] = $row['embeddedObjectID']; - // store message to embedded object assignment if (!isset($this->messageEmbeddedObjects[$row['messageObjectTypeID']][$row['messageID']][$row['embeddedObjectTypeID']])) { $this->messageEmbeddedObjects[$row['messageObjectTypeID']][$row['messageID']][$row['embeddedObjectTypeID']] = [];