diff --git a/Classes/ViewHelpers/Form/UploadedResourceViewHelper.php b/Classes/ViewHelpers/Form/UploadedResourceViewHelper.php index 560c2a2..e82a183 100644 --- a/Classes/ViewHelpers/Form/UploadedResourceViewHelper.php +++ b/Classes/ViewHelpers/Form/UploadedResourceViewHelper.php @@ -20,6 +20,7 @@ use TYPO3\CMS\Extbase\Domain\Model\FileReference; use TYPO3\CMS\Extbase\Property\PropertyMapper; use TYPO3\CMS\Extbase\Security\Cryptography\HashService; +use TYPO3\CMS\Extbase\Validation\Error; use TYPO3\CMS\Fluid\ViewHelpers\Form\AbstractFormFieldViewHelper; use TYPO3\CMS\Fluid\ViewHelpers\Form\UploadViewHelper; @@ -149,7 +150,7 @@ protected function getUploadedResources() $resources = $this->getValueAttribute(); if (is_array($resources)) { foreach ($resources as $resource) { - if ($resource === null) continue; + if ($resource === null || $resource instanceof Error) continue; if ($resource instanceof FileReference) { $return[] = $resource; continue;