Skip to content

Commit

Permalink
watchonly: no err message when user cancels keystore connect prompt
Browse files Browse the repository at this point in the history
Cancel by user is an expected outcome and not an actual error.
  • Loading branch information
benma committed Nov 9, 2023
1 parent 4f0fbbd commit e7b99fa
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions backend/coins/btc/handlers/handlers.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
package handlers

import (
"context"
"encoding/json"
"fmt"
"math/big"
Expand Down Expand Up @@ -542,6 +543,10 @@ func (handlers *Handlers) postVerifyExtendedPublicKey(r *http.Request) (interfac
}, nil
}
canVerify, err := btcAccount.VerifyExtendedPublicKey(input.SigningConfigIndex)
// User canceled keystore connect prompt - no special action or message needed in the frontend.
if errp.Cause(err) == context.Canceled {
return result{Success: true}, nil
}
if err != nil {
return result{Success: false, ErrorMessage: err.Error()}, nil
}
Expand Down

0 comments on commit e7b99fa

Please sign in to comment.