diff --git a/Services/VideoInsertService.php b/Services/VideoInsertService.php index 312eb7c..d3e943c 100644 --- a/Services/VideoInsertService.php +++ b/Services/VideoInsertService.php @@ -129,7 +129,9 @@ private function generateYoutubeDocument(MultimediaObject $multimediaObject, Tag ]); if ($youtube) { - return $youtube; + $this->documentManager->remove($youtube); + $multimediaObject->removeProperty('youtubeurl'); + $this->documentManager->flush(); } $youtube = new Youtube();