Even if that is the case -- if he has no hats, then the statement is technically true, and regardless of whether he intended to lie or not, he made a true statement.