more explicit null/undefined type checks