update method

void update(
  1. DocumentReference<Object?> document,
  2. Map<String, dynamic> data
)

Updates a given document.

If the document does not yet exist, an exception will be thrown.

Implementation

void update(DocumentReference document, Map<String, dynamic> data) {
  assert(
    document.firestore == _firestore,
    'the document provided is from a different Firestore instance',
  );
  return _delegate.update(
    document.path,
    _CodecUtility.replaceValueWithDelegatesInMap(data)!,
  );
}