[BUGFIX] EXT:filelist Fixed exception when creating new text file 09/55809/2
authorMichael Oehlhof <typo3@oehlhof.de>
Sun, 21 Jan 2018 11:50:51 +0000 (12:50 +0100)
committerStefan Neufeind <typo3.neufeind@speedpartner.de>
Tue, 20 Feb 2018 03:38:28 +0000 (04:38 +0100)
The exception does not occur with the LocalDriver.
For testing use the driver mentioned in the forge issue.

Resolves: #83627
Releases: master, 8.7
Change-Id: Iae5fef2cc1ca704998975aba4fb6f5e48aeec4b1
Reviewed-on: https://review.typo3.org/55809
Reviewed-by: Stefan Neufeind <typo3.neufeind@speedpartner.de>
Tested-by: Stefan Neufeind <typo3.neufeind@speedpartner.de>
typo3/sysext/backend/Classes/Controller/File/FileController.php

index a8df2e6..22f4954 100644 (file)
@@ -173,8 +173,11 @@ class FileController
 
         // go and edit the new created file
         if ($request->getParsedBody()['edit']) {
+            /** @var \TYPO3\CMS\Core\Resource\File $file */
+            $file = $this->fileData['newfile'][0];
+            $properties = $file->getProperties();
             $urlParameters = [
-                'target' => $this->file['newfile'][0]['target'] . $this->file['newfile'][0]['data']
+                'target' =>  $properties['storage'] . ':' . $properties['identifier']
             ];
             if ($this->redirect) {
                 $urlParameters['returnUrl'] = $this->redirect;