Co-authored-by: Marko <marko@baricevic.me>
This commit is contained in:
parent
0390254b29
commit
f42fc60826
@ -60,9 +60,6 @@ func (m *LegacyAminoPubKey) VerifyMultisignature(getSignBytes multisigtypes.GetS
|
||||
if int(m.Threshold) <= 0 {
|
||||
return fmt.Errorf("invalid threshold: must be > 0, got %d", m.Threshold)
|
||||
}
|
||||
if len(pubKeys) <= int(m.Threshold) {
|
||||
return fmt.Errorf("invalid N-M multisig: N (%d) must be > M (%d)", len(pubKeys), m.Threshold)
|
||||
}
|
||||
// ensure bit array is the correct size
|
||||
if len(pubKeys) != size {
|
||||
return fmt.Errorf("bit array size is incorrect, expecting: %d", len(pubKeys))
|
||||
|
||||
@ -508,18 +508,6 @@ func TestVerifyMultisignatureNMRule(t *testing.T) {
|
||||
m: 0,
|
||||
expectErr: "invalid threshold: must be > 0, got 0",
|
||||
},
|
||||
{
|
||||
name: "invalid: N=M",
|
||||
n: 3,
|
||||
m: 3,
|
||||
expectErr: "invalid N-M multisig: N (3) must be > M (3)",
|
||||
},
|
||||
{
|
||||
name: "invalid: N < M",
|
||||
n: 2,
|
||||
m: 3,
|
||||
expectErr: "invalid N-M multisig: N (2) must be > M (3)",
|
||||
},
|
||||
}
|
||||
|
||||
for _, tc := range tests {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user