diff --git a/lib/Service/DirectoryService.php b/lib/Service/DirectoryService.php index dd825002..5dd45779 100644 --- a/lib/Service/DirectoryService.php +++ b/lib/Service/DirectoryService.php @@ -297,7 +297,7 @@ public function updateListing(array $newListing, array $oldListing): array{ // Do not update version, because we copy the version from the source $newListing = $this->objectService->saveObject('listing', $oldListing, false); - return $newListing->jsonSerialize(); + return $newListing instanceof Listing === true ? $newListing->jsonSerialize() : $newListing; } /**