docs: @Nullable
    private DocumentChange modifyDoc(QueryDocumentSnapshot newDocument) {
      ResourcePath resourcePath = newDocument.getReference().getResourcePath();
      DocumentSnapshot oldDocument = documentSet.getDocument(resourcePath);
  
      if (!oldDocument.getUpdateTime().equals(newDocument.getUpdateTime())) {
        int oldIndex = documentSet.indexOf(resourcePath);
        documentSet = documentSet.remove(resourcePath);
        documentSet = documentSet.add(newDocument);
        int newIndex = documentSet.indexOf(resourcePath);
        return new DocumentChange(newDocument, Type.MODIFIED, oldIndex, newIndex);
      }
      return null;
    }