[BUGFIX] Fix regression in ResourceCompressor 14/25614/2
authorMarkus Klein <klein.t3@mfc-linz.at>
Thu, 21 Nov 2013 15:28:50 +0000 (16:28 +0100)
committerMarkus Klein <klein.t3@mfc-linz.at>
Thu, 21 Nov 2013 15:53:38 +0000 (16:53 +0100)
Resolves: #53844
Related: #53243
Releases: 6.2, 6.1, 6.0
Change-Id: I7f6a178b063d71c9182316a81e787c9ab5246b8e
Reviewed-on: https://review.typo3.org/25614
Reviewed-by: Markus Klein
Tested-by: Markus Klein
typo3/sysext/core/Classes/Resource/ResourceCompressor.php

index 52d7f97..2a924b0 100644 (file)
@@ -304,11 +304,11 @@ class ResourceCompressor {
                                }
                                $filename = $filesToInclude[$key];
                        }
-                       $filepath = GeneralUtility::resolveBackPath($this->rootPath . $filename);
-                       if (@file_exists($filepath)) {
-                               $unique = $filepath . filemtime($filepath) . filesize($filepath);
+                       $filenameAbsolute = GeneralUtility::resolveBackPath($this->rootPath . $filename);
+                       if (@file_exists($filenameAbsolute)) {
+                               $unique .= $filenameAbsolute . filemtime($filenameAbsolute) . filesize($filenameAbsolute);
                        } else {
-                               $unique = $filepath;
+                               $unique .= $filenameAbsolute;
                        }
                }
                $targetFile = $this->targetDirectory . 'merged-' . md5($unique) . '.' . $type;