From c0221d76e6534a7c264c24a7b1c6af73dad2b5ed Mon Sep 17 00:00:00 2001 From: Ekaterina Lebedeva Date: Fri, 27 Dec 2024 15:31:06 +0300 Subject: [PATCH] [#1577] node/container: Fix typo Signed-off-by: Ekaterina Lebedeva --- cmd/frostfs-node/config/container/container.go | 2 +- pkg/morph/client/container/containers_of.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cmd/frostfs-node/config/container/container.go b/cmd/frostfs-node/config/container/container.go index b0b8043d6..1cd64a6f8 100644 --- a/cmd/frostfs-node/config/container/container.go +++ b/cmd/frostfs-node/config/container/container.go @@ -6,7 +6,7 @@ const ( subsection = "container" listStreamSubsection = "list_stream" - // ContainerBatchSizeDefault represents he maximum amount of containers to send via stream at once. + // ContainerBatchSizeDefault represents the maximum amount of containers to send via stream at once. ContainerBatchSizeDefault = 1000 ) diff --git a/pkg/morph/client/container/containers_of.go b/pkg/morph/client/container/containers_of.go index 6381a14c0..074a586be 100644 --- a/pkg/morph/client/container/containers_of.go +++ b/pkg/morph/client/container/containers_of.go @@ -36,7 +36,6 @@ func (c *Client) IterateContainersOf(idUser *user.ID, cb func(item cid.ID) error rawID = idUser.WalletBytes() } - cnrHash := c.client.ContractAddress() itemCb := func(item stackitem.Item) error { id, err := getCIDfromStackItem(item) if err != nil { @@ -57,6 +56,7 @@ func (c *Client) IterateContainersOf(idUser *user.ID, cb func(item cid.ID) error // 512 is big enough value and it is beautiful. const batchSize = 512 + cnrHash := c.client.ContractAddress() err := c.client.Morph().TestInvokeIterator(itemCb, batchSize, cnrHash, containersOfMethod, rawID) if err != nil && errors.Is(err, unwrap.ErrNoSessionID) { return c.iterate(idUser, cb)