Explorar el Código

文件上传value转数组

jqh hace 4 años
padre
commit
9383a32527
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      src/Form/Field/File.php

+ 1 - 1
src/Form/Field/File.php

@@ -152,7 +152,7 @@ class File extends Field implements UploadFieldInterface
     {
         $previews = [];
 
-        foreach ($this->value() as $value) {
+        foreach (Helper::array($this->value()) as $value) {
             $previews[] = [
                 'id'   => $value,
                 'path' => basename($value),