Skip to content

Commit

Permalink
core/vm: remove redundant error checks (#29692)
Browse files Browse the repository at this point in the history
  • Loading branch information
AaronChen0 committed May 2, 2024
1 parent 682ee82 commit bc609e8
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions core/vm/contracts.go
Expand Up @@ -1123,9 +1123,6 @@ func (c *bls12381MapG1) Run(input []byte) ([]byte, error) {

// Compute mapping
r := bls12381.MapToG1(fe)
if err != nil {
return nil, err
}

// Encode the G1 point to 128 bytes
return encodePointG1(&r), nil
Expand Down Expand Up @@ -1159,9 +1156,6 @@ func (c *bls12381MapG2) Run(input []byte) ([]byte, error) {

// Compute mapping
r := bls12381.MapToG2(bls12381.E2{A0: c0, A1: c1})
if err != nil {
return nil, err
}

// Encode the G2 point to 256 bytes
return encodePointG2(&r), nil
Expand Down

0 comments on commit bc609e8

Please sign in to comment.