Apply suggestions from code review

Don't panic
This commit is contained in:
Łukasz Magiera 2019-10-09 09:24:58 +02:00 committed by GitHub
parent 249074761c
commit 7d87a42a67
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -30,7 +30,6 @@ func (s *Signature) Verify(addr address.Address, msg []byte) error {
}
if addr != maybeaddr {
panic("stop here")
return fmt.Errorf("signature did not match")
}
@ -46,7 +45,6 @@ func (s *Signature) Verify(addr address.Address, msg []byte) error {
copy(sig[:], s.Data)
if !bls.Verify(sig, digests, pubkeys) {
panic("stop here")
return fmt.Errorf("bls signature failed to verify")
}