This is temp fix for when document is missing

fixes #5366