diff --git a/action_access_key.go b/action_access_key.go index b610c968..030b77ca 100644 --- a/action_access_key.go +++ b/action_access_key.go @@ -61,7 +61,7 @@ func (c *Client) GetAccessKey(ctx context.Context, xPubID, id string) (*AccessKe if err != nil { return nil, err } else if accessKey == nil { - return nil, ErrMissingXpub + return nil, ErrAccessKeyNotFound } // make sure this is the correct accessKey diff --git a/errors.go b/errors.go index a97db492..17562034 100644 --- a/errors.go +++ b/errors.go @@ -43,6 +43,9 @@ var ErrXpubIDMisMatch = errors.New("xpub_id mismatch") // ErrMissingXpub is when the field is required but missing var ErrMissingXpub = errors.New("could not find xpub") +// ErrAccessKeyNotFound is when the access key not found +var ErrAccessKeyNotFound = errors.New("access key not found") + // ErrMissingLockingScript is when the field is required but missing var ErrMissingLockingScript = errors.New("could not find locking script")