You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you use HTTPFoundation's Request, and then get specific input bags (query/request,...), the get may return string|null. However, if you pass parameter #2$default as non-null value, it will never return null, and always a string.
So for example this code can never return null;
$request->query->get('name', 'default value');
Currently, because the typehint on the function is string|null, PHPStan will complain if you pass this to a function with a non-null argument, even though it will never return null;
Parameter #2 $name of class Foo constructor expects string, string|null given