Wrap all errors with tracerr

This commit is contained in:
Eduard S
2020-11-30 12:58:36 +01:00
parent 879af66a2a
commit ced42634da
59 changed files with 1324 additions and 1268 deletions

View File

@@ -5,6 +5,7 @@ import (
"math/big"
ethCommon "github.com/ethereum/go-ethereum/common"
"github.com/hermeznetwork/tracerr"
"github.com/iden3/go-iden3-crypto/babyjub"
)
@@ -29,7 +30,7 @@ func EthAddrToBigInt(a ethCommon.Address) *big.Int {
func BJJFromStringWithChecksum(s string) (*babyjub.PublicKey, error) {
b, err := hex.DecodeString(s)
if err != nil {
return nil, err
return nil, tracerr.Wrap(err)
}
pkBytes := SwapEndianness(b)
var pkComp babyjub.PublicKeyComp