This my code:
$sftp = ssh2_sftp($connection);
if ($sftp === false) {
This is the psalm error:
ERROR: TypeDoesNotContainType - src/MyFile.php:159:13 - resource does not contain false
if ($sftp === false) {
..but the php manual says ssh2_sftp
can return false:
This method returns an SSH2 SFTP resource for use with all other ssh2_sftp_*() methods and the ssh2.sftp:// fopen wrapper, or FALSE on failure.
What am I missing here, or what am I not understanding?