handle unset data issues in search