From 1df3c9365cb0c19ce8fe07de321dcca933ceafbb Mon Sep 17 00:00:00 2001 From: Brown Date: Mon, 14 Sep 2020 09:59:57 -0400 Subject: [PATCH] Fix template check --- src/Psalm/Internal/Analyzer/FunctionLike/ReturnTypeAnalyzer.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Psalm/Internal/Analyzer/FunctionLike/ReturnTypeAnalyzer.php b/src/Psalm/Internal/Analyzer/FunctionLike/ReturnTypeAnalyzer.php index 3e46279d0..a6bc6cd59 100644 --- a/src/Psalm/Internal/Analyzer/FunctionLike/ReturnTypeAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/FunctionLike/ReturnTypeAnalyzer.php @@ -156,10 +156,10 @@ class ReturnTypeAnalyzer } } - /** @psalm-suppress PossiblyUndefinedStringArrayOffset */ if ($return_type && (!$return_type->from_docblock || ($return_type->isNullable() + && !$return_type->hasTemplate() && !$return_type->getAtomicTypes()['null']->from_docblock ) )