[#883] adm: Add domainOf function to resolve NNS domain

Signed-off-by: Alex Vanin <a.vanin@yadro.com>
This commit is contained in:
Alexey Vanin 2023-12-21 13:59:46 +03:00
parent ac0821a1a5
commit b1eab1de54
10 changed files with 18 additions and 14 deletions

View file

@ -20,7 +20,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 := nnsResolveHash(inv, cs.Hash, netmapContract+".frostfs")
nmHash, err := nnsResolveHash(inv, cs.Hash, domainOf(netmapContract))
commonCmd.ExitOnErr(cmd, "can't get netmap contract hash: %w", err)
res, err := inv.Call(nmHash, "netmapCandidates")