[#521] *: use stdlib errors package

Signed-off-by: Evgenii Stratonikov <evgeniy@nspcc.ru>
This commit is contained in:
Evgenii Stratonikov 2021-05-18 11:12:51 +03:00 committed by Alex Vanin
parent 43e575cec2
commit 71b87155ef
171 changed files with 825 additions and 674 deletions

View file

@ -2,10 +2,10 @@ package putsvc
import (
"context"
"fmt"
"github.com/nspcc-dev/neofs-node/pkg/services/object"
putsvc "github.com/nspcc-dev/neofs-node/pkg/services/object/put"
"github.com/pkg/errors"
)
// Service implements Put operation of Object service v2.
@ -37,7 +37,7 @@ func NewService(opts ...Option) *Service {
func (s *Service) Put(ctx context.Context) (object.PutObjectStream, error) {
stream, err := s.svc.Put(ctx)
if err != nil {
return nil, errors.Wrapf(err, "(%T) could not open object put stream", s)
return nil, fmt.Errorf("(%T) could not open object put stream: %w", s, err)
}
return &streamer{