Description
Bug report
When using the PDO::quote() method, which has a return signature of string|false
phpstan will throw an error when checking if the returned value is false
. This should be allowed, since the function can return false
value.
If it weren't a strict check the return value ''
(empty string) would trigger the if-condition in the playground linked.
Code snippet that reproduces the problem
https://phpstan.org/r/4a7accc9-ee76-4fc2-be27-4a23b12f4be6
Expected output
There should not be any errors.
Did PHPStan help you today? Did it make you happy in any way?
Amazing tool! Good job!
Activity