From a358255c1b811172aff963144317314988d20e8f Mon Sep 17 00:00:00 2001 From: Dmitrii Stepanov Date: Tue, 18 Apr 2023 12:04:31 +0300 Subject: [PATCH] [#265] node: Drop unused Resolve unused linter. Signed-off-by: Dmitrii Stepanov --- cmd/frostfs-cli/modules/control/shards_set_mode.go | 7 ------- pkg/morph/client/netmap/config.go | 10 ---------- 2 files changed, 17 deletions(-) diff --git a/cmd/frostfs-cli/modules/control/shards_set_mode.go b/cmd/frostfs-cli/modules/control/shards_set_mode.go index 4f6e24082..135c0efa6 100644 --- a/cmd/frostfs-cli/modules/control/shards_set_mode.go +++ b/cmd/frostfs-cli/modules/control/shards_set_mode.go @@ -137,13 +137,6 @@ func setShardMode(cmd *cobra.Command, _ []string) { cmd.Println("Shard mode update request successfully sent.") } -func getShardID(cmd *cobra.Command) []byte { - sid, _ := cmd.Flags().GetString(shardIDFlag) - raw, err := base58.Decode(sid) - commonCmd.ExitOnErr(cmd, "incorrect shard ID encoding: %w", err) - return raw -} - func getShardIDList(cmd *cobra.Command) [][]byte { all, _ := cmd.Flags().GetBool(shardAllFlag) if all { diff --git a/pkg/morph/client/netmap/config.go b/pkg/morph/client/netmap/config.go index 71ffa2a7a..c837cbf0c 100644 --- a/pkg/morph/client/netmap/config.go +++ b/pkg/morph/client/netmap/config.go @@ -136,16 +136,6 @@ func (c *Client) readUInt64Config(key string) (uint64, error) { return uint64(v.(int64)), nil } -func (c *Client) readStringConfig(key string) (string, error) { - v, err := c.config([]byte(key), StringAssert) - if err != nil { - return "", err - } - - // StringAssert is guaranteed to return string if the error is nil. - return v.(string), nil -} - // reads boolean value by the given key from the FrostFS network configuration // stored in the Sidechain. Returns false if key is not presented. func (c *Client) readBoolConfig(key string) (bool, error) {