[#932] adm: Move const
to package constants
Signed-off-by: Anton Nikiforov <an.nikiforov@yadro.com>
This commit is contained in:
parent
814c411f4a
commit
e2cee4cf09
29 changed files with 140 additions and 114 deletions
|
@ -4,6 +4,7 @@ import (
|
|||
"fmt"
|
||||
"strings"
|
||||
|
||||
"git.frostfs.info/TrueCloudLab/frostfs-node/cmd/frostfs-adm/internal/modules/morph/constants"
|
||||
"git.frostfs.info/TrueCloudLab/frostfs-node/cmd/frostfs-adm/internal/modules/morph/util"
|
||||
"github.com/nspcc-dev/neo-go/pkg/io"
|
||||
"github.com/nspcc-dev/neo-go/pkg/rpcclient/management"
|
||||
|
@ -23,7 +24,7 @@ func ForceNewEpochCmd(cmd *cobra.Command, _ []string) error {
|
|||
return fmt.Errorf("can't get NNS contract info: %w", err)
|
||||
}
|
||||
|
||||
nmHash, err := util.NNSResolveHash(wCtx.ReadOnlyInvoker, cs.Hash, util.DomainOf(util.NetmapContract))
|
||||
nmHash, err := util.NNSResolveHash(wCtx.ReadOnlyInvoker, cs.Hash, util.DomainOf(constants.NetmapContract))
|
||||
if err != nil {
|
||||
return fmt.Errorf("can't get netmap contract hash: %w", err)
|
||||
}
|
||||
|
|
|
@ -2,6 +2,7 @@ package netmap
|
|||
|
||||
import (
|
||||
"git.frostfs.info/TrueCloudLab/frostfs-node/cmd/frostfs-adm/internal/commonflags"
|
||||
"git.frostfs.info/TrueCloudLab/frostfs-node/cmd/frostfs-adm/internal/modules/morph/constants"
|
||||
"git.frostfs.info/TrueCloudLab/frostfs-node/cmd/frostfs-adm/internal/modules/morph/util"
|
||||
commonCmd "git.frostfs.info/TrueCloudLab/frostfs-node/cmd/internal/common"
|
||||
"git.frostfs.info/TrueCloudLab/frostfs-node/pkg/morph/client/netmap"
|
||||
|
@ -21,7 +22,7 @@ func listNetmapCandidatesNodes(cmd *cobra.Command, _ []string) {
|
|||
cs, err := r.GetContractByID(1)
|
||||
commonCmd.ExitOnErr(cmd, "can't get NNS contract info: %w", err)
|
||||
|
||||
nmHash, err := util.NNSResolveHash(inv, cs.Hash, util.DomainOf(util.NetmapContract))
|
||||
nmHash, err := util.NNSResolveHash(inv, cs.Hash, util.DomainOf(constants.NetmapContract))
|
||||
commonCmd.ExitOnErr(cmd, "can't get netmap contract hash: %w", err)
|
||||
|
||||
res, err := inv.Call(nmHash, "netmapCandidates")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue