Psalm seems to think of "set" as a type - #1722
Conversation
|
Hmm, I don't understand what the issue is.. Psalm isn't complaining about it at all, and this PR only increases the amount of psalm-errors? |
|
Hi @tvdijen , it is hard to show within the SSP project because of its psalm error levels and which things are set to just info. and for phpunit it passes fine. However when running
It is basically saying that the return type of So I think it should be |
|
\n This pull request has been automatically locked since there has \n not been any recent activity after it was closed.\n Please open a new issue for related bugs. |
I'm am certainly no psalm expert. In my attempts to add more psalm to the ratelimit module psalm was complaining that Configuration's getOptionalString could never return null even if default is null. I think that psalm maybe doesn't understand
$default is setsince when I changed it to$default is nullor$default is string(and adjust ternary expression) then psalm stopped complaining.Open to other ideas.