From 7de81cd5850a733c1c32aef8d7ecb4af497d21f2 Mon Sep 17 00:00:00 2001 From: Leonard Lyubich Date: Fri, 11 Feb 2022 19:19:45 +0300 Subject: [PATCH] [#131] pool: Fix ineffectual error assignments Signed-off-by: Leonard Lyubich --- pool/pool.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pool/pool.go b/pool/pool.go index 45afc1a5..79ad6584 100644 --- a/pool/pool.go +++ b/pool/pool.go @@ -895,6 +895,9 @@ func (p *pool) GetObject(ctx context.Context, addr address.Address, opts ...Call return nil }) + if err != nil { + return nil, err + } return &res, nil } @@ -936,6 +939,9 @@ func (p *pool) HeadObject(ctx context.Context, addr address.Address, opts ...Cal return nil }) + if err != nil { + return nil, err + } return &obj, nil }