[BUGFIX] Fix undefined variable to evaluate `fileFolder_recursions` correctly 74/54174/4
authorAndreas Fernandez <a.fernandez@scripting-base.de>
Tue, 19 Sep 2017 14:24:38 +0000 (16:24 +0200)
committerFrank Naegler <frank.naegler@typo3.org>
Fri, 22 Sep 2017 09:17:50 +0000 (11:17 +0200)
Resolves: #82512
Releases: master, 8.7
Change-Id: Ibfbd1a8e347f5b25871f5d073994bdb2af264051
Reviewed-on: https://review.typo3.org/54174
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Georg Ringer <georg.ringer@gmail.com>
Tested-by: Georg Ringer <georg.ringer@gmail.com>
Reviewed-by: Frank Naegler <frank.naegler@typo3.org>
Tested-by: Frank Naegler <frank.naegler@typo3.org>
typo3/sysext/backend/Classes/Form/FormDataProvider/AbstractItemProvider.php

index 4ff6b93..2b84d91 100644 (file)
@@ -397,8 +397,8 @@ abstract class AbstractItemProvider
             ) {
                 $fileExtensionList = $result['processedTca']['columns'][$fieldName]['config']['fileFolder_extList'];
             }
-            $recursionLevels = isset($fieldValue['config']['fileFolder_recursions'])
-                ? MathUtility::forceIntegerInRange($fieldValue['config']['fileFolder_recursions'], 0, 99)
+            $recursionLevels = isset($result['processedTca']['columns'][$fieldName]['config']['fileFolder_recursions'])
+                ? MathUtility::forceIntegerInRange($result['processedTca']['columns'][$fieldName]['config']['fileFolder_recursions'], 0, 99)
                 : 99;
             $fileArray = GeneralUtility::getAllFilesAndFoldersInPath([], $fileFolder, $fileExtensionList, 0, $recursionLevels);
             $fileArray = GeneralUtility::removePrefixPathFromList($fileArray, $fileFolder);