diff --git a/src/Controller/MediaController.php b/src/Controller/MediaController.php index bce62db51..112dc19d5 100755 --- a/src/Controller/MediaController.php +++ b/src/Controller/MediaController.php @@ -85,7 +85,7 @@ public function previewAction(Request $request): Response $form->handleRequest($request); - if ($form->isValid()) { + if ($form->isSubmitted() && $form->isValid()) { $this->setMediaLocales($media, $request); $this->setMediaPathIfExists($media); $mediaTemplate = $this->mediaProviderResolver->resolveProvider($media)->getTemplate();