Based on https://github.com/dimagi/commcare-hq/blob/master/corehq/apps/hqwebapp/views.py#L775, it looks like we should just be checking if ```xform_json.get('doc_type') == 'XFormInstance'```.  I checked the error in the ticket and the document type is "CommCareCase-Deleted".