From 9e48ccf743cc8c827c116c82d38011cba98918af Mon Sep 17 00:00:00 2001 From: Giuseppe Lo Presti Date: Wed, 6 Mar 2024 19:11:19 +0100 Subject: [PATCH] Future implementation for passing app in eos-grpc --- pkg/eosclient/eosgrpc/eosgrpc.go | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/pkg/eosclient/eosgrpc/eosgrpc.go b/pkg/eosclient/eosgrpc/eosgrpc.go index 63870c5ceb6..c1da734113c 100644 --- a/pkg/eosclient/eosgrpc/eosgrpc.go +++ b/pkg/eosclient/eosgrpc/eosgrpc.go @@ -529,12 +529,12 @@ func (c *Client) SetAttr(ctx context.Context, auth eosclient.Authorization, attr if errorIfExists { msg.Create = true } - - rq.Command = &erpc.NSRequest_Xattr{Xattr: msg} // if app != "" { - // rq.Header.Set("app", app) + // msg.App = []byte(app) // } + rq.Command = &erpc.NSRequest_Xattr{Xattr: msg} + // Now send the req and see what happens resp, err := c.cl.Exec(appctx.ContextGetClean(ctx), rq) e := c.getRespError(resp, err) @@ -579,11 +579,12 @@ func (c *Client) UnsetAttr(ctx context.Context, auth eosclient.Authorization, at msg.Id = new(erpc.MDId) msg.Id.Path = []byte(path) - rq.Command = &erpc.NSRequest_Xattr{Xattr: msg} // if app != "" { - // rq.Header.Set("app", app) + // msg.App = []byte(app) // } + rq.Command = &erpc.NSRequest_Xattr{Xattr: msg} + // Now send the req and see what happens resp, err := c.cl.Exec(appctx.ContextGetClean(ctx), rq)