update method

Transaction update(
  1. DocumentReference documentReference,
  2. Map<String, dynamic> data
)

Updates fields in the document referred to by documentReference. The update will fail if applied to a document that does not exist.

Implementation

Transaction update(
    DocumentReference documentReference, Map<String, dynamic> data) {
  assert(documentReference.firestore == _firestore,
      'the document provided is from a different Firestore instance');

  return Transaction._(
      _firestore,
      _delegate.update(documentReference.path,
          _CodecUtility.replaceValueWithDelegatesInMap(data)!));
}