diff --git a/src/lib/Resolver/DomainContentMutationResolver.php b/src/lib/Resolver/DomainContentMutationResolver.php index d005105..fa1fade 100644 --- a/src/lib/Resolver/DomainContentMutationResolver.php +++ b/src/lib/Resolver/DomainContentMutationResolver.php @@ -55,7 +55,7 @@ public function __construct( $this->itemFactory = $relatedContentItemFactory; } - public function updateDomainContent($input, Argument $args, $versionNo, $language): RepositoryValues\Content\Content + public function updateDomainContent($input, Argument $args, $versionNo, $language): Item { if (isset($args['id'])) { $idArray = GlobalId::fromGlobalId($args['id']); @@ -136,7 +136,7 @@ public function updateDomainContent($input, Argument $args, $versionNo, $languag throw new UserError('You are not authorized to publish this version'); } - return $this->getContentService()->loadContent($contentDraft->id); + return $this->itemFactory->fromContent($this->getContentService()->loadContent($contentDraft->id)); } public function createDomainContent($input, $contentTypeIdentifier, $parentLocationId, $language): Item