mirror of
https://github.com/silverstripe/silverstripe-userforms.git
synced 2024-10-22 17:05:42 +02:00
Fix empty file fields
Fix for empty file fields when not all upload fields are used.
This commit is contained in:
parent
e0d9399654
commit
9a5144104c
@ -679,7 +679,7 @@ JS
|
|||||||
|
|
||||||
if (!empty($data[$field->Name])) {
|
if (!empty($data[$field->Name])) {
|
||||||
if (in_array("EditableFileField", $field->getClassAncestry())) {
|
if (in_array("EditableFileField", $field->getClassAncestry())) {
|
||||||
if (isset($_FILES[$field->Name])) {
|
if (!empty($_FILES[$field->Name]['name'])) {
|
||||||
$foldername = $field->getFormField()->getFolderName();
|
$foldername = $field->getFormField()->getFolderName();
|
||||||
|
|
||||||
// create the file from post data
|
// create the file from post data
|
||||||
|
Loading…
Reference in New Issue
Block a user