error out when trying to create multisig with no addresses

This commit is contained in:
whyrusleeping 2020-07-06 09:40:56 -07:00
parent 516e31d37c
commit 0964c0a8a1

View File

@ -70,6 +70,10 @@ var msigCreateCmd = &cli.Command{
defer closer()
ctx := ReqContext(cctx)
if cctx.Args().Len() < 1 {
return fmt.Errorf("multisigs must have at least one signer")
}
var addrs []address.Address
for _, a := range cctx.Args().Slice() {
addr, err := address.NewFromString(a)