I have a fluid form with one filed as file upload. The file upload field is optional. I'm using Helhum's fileupload property converter. But the problem is that when the file is null then an error occured. Model is
/**
* file
*
* @var \TYPO3\CMS\Extbase\Domain\Model\FileReference
*/
protected $file = null;
/**
* Returns the file
*
* @return \TYPO3\CMS\Extbase\Domain\Model\FileReference $file
*/
public function getFile()
{
return $this->file;
}
/**
* Sets the file
*
* @param \TYPO3\CMS\Extbase\Domain\Model\FileReference $file
* @return void
*/
public function setFile($file = NULL)
{
$this->file = $file;
}
and my form is
<f:form.upload property="file" />