I think checking if $info is false might be enough here.