diff --git a/banderwagon/element.go b/banderwagon/element.go index ca14a32..968d38b 100644 --- a/banderwagon/element.go +++ b/banderwagon/element.go @@ -251,8 +251,8 @@ func (p *Element) SetBytesUncompressed(buf []byte, trusted bool) error { if point == nil { return fmt.Errorf("point not in the curve") } - calcualtedYBytes := point.Y.Bytes() - if !bytes.Equal(calcualtedYBytes[:], buf[coordinateSize:]) { + calculatedYBytes := point.Y.Bytes() + if !bytes.Equal(calculatedYBytes[:], buf[coordinateSize:]) { return fmt.Errorf("provided Y coordinate doesn't correspond to X") } y = point.Y