From acdcd16b4d568e5608cc1ac2fd9d3faecd9a8ab0 Mon Sep 17 00:00:00 2001 From: Chi Vinh Le Date: Mon, 24 Sep 2018 20:16:29 +0200 Subject: [PATCH] Add some comments --- src/core/client/stream/mutations/CreateCommentMutation.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/core/client/stream/mutations/CreateCommentMutation.ts b/src/core/client/stream/mutations/CreateCommentMutation.ts index b2f1b78fe..c20406746 100644 --- a/src/core/client/stream/mutations/CreateCommentMutation.ts +++ b/src/core/client/stream/mutations/CreateCommentMutation.ts @@ -31,6 +31,9 @@ function sharedUpdater( } } +/** + * update integrates new comment into the CommentConnection. + */ function update(store: RecordSourceSelectorProxy, input: CreateCommentInput) { // Get the payload returned from the server. const payload = store.getRootField("createComment")!; @@ -69,6 +72,9 @@ function update(store: RecordSourceSelectorProxy, input: CreateCommentInput) { } } +/** + * localUpdate is like update but updates the `localReplies` endpoint. + */ function localUpdate( store: RecordSourceSelectorProxy, input: CreateCommentInput