From 6d6fd1e849b78b32e1a84a193126f519be706451 Mon Sep 17 00:00:00 2001 From: mcrakhman Date: Thu, 16 Mar 2023 18:27:19 +0100 Subject: [PATCH] Update rpc err in pull space --- commonspace/spaceservice.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/commonspace/spaceservice.go b/commonspace/spaceservice.go index 0fc01125..47427831 100644 --- a/commonspace/spaceservice.go +++ b/commonspace/spaceservice.go @@ -17,6 +17,7 @@ import ( "github.com/anytypeio/any-sync/commonspace/syncstatus" "github.com/anytypeio/any-sync/net/peer" "github.com/anytypeio/any-sync/net/pool" + "github.com/anytypeio/any-sync/net/rpc/rpcerr" "github.com/anytypeio/any-sync/nodeconf" "sync/atomic" ) @@ -216,6 +217,7 @@ func (s *spaceService) getSpaceStorageFromRemote(ctx context.Context, id string) cl := spacesyncproto.NewDRPCSpaceSyncClient(p) res, err := cl.SpacePull(ctx, &spacesyncproto.SpacePullRequest{Id: id}) if err != nil { + err = rpcerr.Unwrap(err) return }