Skip to content

Commit 01aa067

Browse files
author
Stanislav Idolov
authored
ENGCOM-2327: Avoid undefined index warning when using uppercase reserved word #16785
2 parents dc8cd62 + a7167bd commit 01aa067

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

dev/tests/static/framework/Magento/Sniffs/NamingConventions/ReservedWordsSniff.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ protected function validateNamespace(File $sourceFile, $stackPtr)
6464
'Cannot use "%s" in namespace as it is reserved since PHP %s',
6565
$stackPtr,
6666
'Namespace',
67-
[$namespacePart, $this->reservedWords[$namespacePart]]
67+
[$namespacePart, $this->reservedWords[strtolower($namespacePart)]]
6868
);
6969
}
7070
$stackPtr++;

0 commit comments

Comments
 (0)