handling missing document