From d548ebe834a291d7fd51dc2ad11b670a3396e4d6 Mon Sep 17 00:00:00 2001 From: Marcel Werk Date: Mon, 5 Mar 2018 12:31:54 +0100 Subject: [PATCH] Made sure that getObjectIDs() returns an array after readObjects() has been called --- wcfsetup/install/files/lib/data/DatabaseObjectList.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wcfsetup/install/files/lib/data/DatabaseObjectList.class.php b/wcfsetup/install/files/lib/data/DatabaseObjectList.class.php index c562d0657a..5d99f07062 100644 --- a/wcfsetup/install/files/lib/data/DatabaseObjectList.class.php +++ b/wcfsetup/install/files/lib/data/DatabaseObjectList.class.php @@ -205,7 +205,7 @@ abstract class DatabaseObjectList implements \Countable, ITraversableObject { } // use table index as array index - $objects = []; + $objects = $this->indexToObject = []; foreach ($this->objects as $object) { $objectID = $object->getObjectID(); $objects[$objectID] = $object; -- 2.20.1