From 078187033bbb07f9344107d726cba4bf1990a460 Mon Sep 17 00:00:00 2001 From: root Date: Mon, 29 Mar 2021 15:06:14 +0200 Subject: [PATCH] Return the copy error in the case of non-streaming http download --- pkg/eosclient/eosgrpc/eos_http/eoshttp.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/eosclient/eosgrpc/eos_http/eoshttp.go b/pkg/eosclient/eosgrpc/eos_http/eoshttp.go index a0953589da..776005f547 100644 --- a/pkg/eosclient/eosgrpc/eos_http/eoshttp.go +++ b/pkg/eosclient/eosgrpc/eos_http/eoshttp.go @@ -342,7 +342,7 @@ func (c *EosHttpClient) GETFile(ctx context.Context, remoteuser, uid, gid, urlpa if stream != nil { // Streaming versus localfile. If we have bene given a dest stream then copy the body into it _, err = io.Copy(stream, resp.Body) - return nil, nil + return err, nil } // If we have not been given a stream to write into then return our stream to read from