function _addDiscriminatorToObject(schema, obj) {
  if (schema == null) {
    return;
  }
  if (schema.discriminatorMapping && !schema.discriminatorMapping.isRoot) {
    obj[schema.discriminatorMapping.key] = schema.discriminatorMapping.value;
  }
}
Given a model and a bulkWrite op, return a thunk that handles casting and
validating the individual op.
@param {Model} originalModel
@param {Object} op
@param {Object} [options]
@api private