aboutsummaryrefslogtreecommitdiff
path: root/key/pub.go
diff options
context:
space:
mode:
Diffstat (limited to 'key/pub.go')
-rw-r--r--key/pub.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/key/pub.go b/key/pub.go
index 7767531..f676226 100644
--- a/key/pub.go
+++ b/key/pub.go
@@ -8,7 +8,7 @@ type Pub struct {
Key [ed25519.PublicKeySize]byte
}
-func (v *Pub) Err() error {
+func (v *Pub) Validate() error {
if v.PKAlg != pkAlg {
return ErrInvalidPK
}
@@ -24,5 +24,5 @@ func NewPub(data []byte) (*Pub, error) {
if err := pub.UnmarshalBinary(data); err != nil {
return nil, err
}
- return pub, pub.Err()
+ return pub, pub.Validate()
}