aboutsummaryrefslogtreecommitdiff
path: root/account.go
diff options
context:
space:
mode:
Diffstat (limited to 'account.go')
-rw-r--r--account.go24
1 files changed, 3 insertions, 21 deletions
diff --git a/account.go b/account.go
index 3fa1ae7..62f1c78 100644
--- a/account.go
+++ b/account.go
@@ -5,7 +5,6 @@ import (
"crypto/rsa"
"encoding/base64"
"io"
- "net/mail"
"strings"
"github.com/square/go-jose"
@@ -16,10 +15,9 @@ const KeySize = 2048
// Account ...
type Account struct {
- contact Contacts
- key *rsa.PrivateKey
- signer jose.Signer
- nonce chan string
+ key *rsa.PrivateKey
+ signer jose.Signer
+ nonce chan string
}
// NewAccount ...
@@ -31,22 +29,6 @@ func NewAccount(key *rsa.PrivateKey) (*Account, error) {
return &Account{key: key, signer: signer}, nil
}
-func (a *Account) AddMail(email string) error {
- m, err := mail.ParseAddress(email)
- if err != nil {
- return err
- }
- a.contact = append(a.contact, Mail(m.Address))
- return nil
-}
-
-func (a *Account) AddPhone(phone string) error {
- if ph := strings.TrimSpace(phone); ph != "" {
- a.contact = append(a.contact, Phone(ph))
- }
- return nil
-}
-
// Signer describes a signing interface
type Signer interface {
Sign([]byte, jose.NonceSource) (io.Reader, error)