From cc4a10e9f1985530ce9332c27896e192001ae3fe Mon Sep 17 00:00:00 2001 From: "M. J. Fromberger" Date: Sat, 21 Aug 2021 15:55:18 -0700 Subject: [PATCH] Clarify the documentation of Client.Batch. --- client.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/client.go b/client.go index 80a0c10..54c4ce3 100644 --- a/client.go +++ b/client.go @@ -319,8 +319,9 @@ func (c *Client) CallResult(ctx context.Context, method string, params, result i // responses return. The responses are returned in the same order as the // original specs, omitting notifications. // -// Any error returned is from sending the batch; the caller must check each -// response for errors from the server. +// Any error reported by Batch represents an error in encoding or sending the +// batch to the server. Errors reported by the server in response to requests +// must be recovered from the responses. func (c *Client) Batch(ctx context.Context, specs []Spec) ([]*Response, error) { reqs := make(jmessages, len(specs)) for i, spec := range specs {