fix for when no record is found