From d1f71e4e63cf0cdc6f334d8520df2f3fb477deb5 Mon Sep 17 00:00:00 2001 From: Alexander Berl Date: Mon, 22 Nov 2021 09:46:40 +0100 Subject: [PATCH 1/2] TASK: Adjust docblock typehint to TYPO3Fluid change The $pathAndFilename argument has been declared nullable in upstream 2.7.1+ and psalm was notifying about this. --- Neos.FluidAdaptor/Classes/View/TemplatePaths.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Neos.FluidAdaptor/Classes/View/TemplatePaths.php b/Neos.FluidAdaptor/Classes/View/TemplatePaths.php index b09317ec54..c0064a24bc 100644 --- a/Neos.FluidAdaptor/Classes/View/TemplatePaths.php +++ b/Neos.FluidAdaptor/Classes/View/TemplatePaths.php @@ -539,7 +539,7 @@ public function setOption($optionName, $value) * ____ * The SH1 hash is a checksum that is based on the file path and last modification date * - * @param string $pathAndFilename + * @param string|null $pathAndFilename * @param string $prefix * @return string * @throws InvalidTemplateResourceException From 84b012f27c798f8280c1b240bd79c0b5e75a8559 Mon Sep 17 00:00:00 2001 From: Alexander Berl Date: Mon, 22 Nov 2021 09:54:13 +0100 Subject: [PATCH 2/2] TASK: Cast possible null to empty string in createIdentifierForFile --- Neos.FluidAdaptor/Classes/View/TemplatePaths.php | 1 + 1 file changed, 1 insertion(+) diff --git a/Neos.FluidAdaptor/Classes/View/TemplatePaths.php b/Neos.FluidAdaptor/Classes/View/TemplatePaths.php index c0064a24bc..fb001bd3c1 100644 --- a/Neos.FluidAdaptor/Classes/View/TemplatePaths.php +++ b/Neos.FluidAdaptor/Classes/View/TemplatePaths.php @@ -546,6 +546,7 @@ public function setOption($optionName, $value) */ protected function createIdentifierForFile($pathAndFilename, $prefix) { + $pathAndFilename = (string)$pathAndFilename; $templateModifiedTimestamp = 0; $isStandardInput = $pathAndFilename === 'php://stdin'; $isFile = is_file($pathAndFilename);