Przeglądaj źródła

[HttpFoundation] fixed request files handling

Antoine Hérault 14 lat temu
rodzic
commit
7bd76610ca
1 zmienionych plików z 4 dodań i 0 usunięć
  1. 4 0
      src/Symfony/Component/HttpFoundation/Request.php

+ 4 - 0
src/Symfony/Component/HttpFoundation/Request.php

@@ -895,6 +895,10 @@ class Request
      */
     protected function fixPhpFilesArray($data)
     {
+        if (!is_array($data)) {
+            return $data;
+        }    
+        
         $fileKeys = array('error', 'name', 'size', 'tmp_name', 'type');
         $keys = array_keys($data);
         sort($keys);