1
0
mirror of https://github.com/danog/psalm.git synced 2024-11-30 04:39:00 +01:00

Prevent crash when suppressing UndefinedTrait

Fixes #4130
This commit is contained in:
Brown 2020-09-04 16:50:10 -04:00 committed by Daniil Gentili
parent be3d130965
commit 866bf583c4
Signed by: danog
GPG Key ID: 8C1BE3B34B230CA7

View File

@ -1520,6 +1520,8 @@ class ClassAnalyzer extends ClassLikeAnalyzer
)) { )) {
return false; return false;
} }
return null;
} else { } else {
if (!$codebase->traitHasCorrectCase($fq_trait_name)) { if (!$codebase->traitHasCorrectCase($fq_trait_name)) {
if (IssueBuffer::accepts( if (IssueBuffer::accepts(