aboutsummaryrefslogtreecommitdiff
path: root/provider.go
diff options
context:
space:
mode:
authorDimitri Sokolyuk <demon@dim13.org>2016-01-04 23:51:46 +0100
committerDimitri Sokolyuk <demon@dim13.org>2016-01-04 23:51:46 +0100
commitd534bb3fd336c8f69a7348a36084b487904b5b6a (patch)
treeb052af6d884a2ba98be9a31fbcfafe956ca39201 /provider.go
parent74e5ab64d63946c4ac1ce7317af08bc0a378ca93 (diff)
Separate contacts
Diffstat (limited to 'provider.go')
-rw-r--r--provider.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/provider.go b/provider.go
index a9ff15a..c6b8e9f 100644
--- a/provider.go
+++ b/provider.go
@@ -175,10 +175,10 @@ func parseHeader(r *http.Response) nextStep {
challenge cert-chain
*/
-func (p *Provider) Register(a *Account) error {
+func (p *Provider) Register(a *Account, c Contacts) error {
r := &Registration{
Resource: ResNewReg,
- Contact: a.contact,
+ Contact: c,
}
resp, err := p.post(p.NewReg, a, r)
if err != nil && err.(Problem).Err != ErrMalformed {
@@ -199,7 +199,7 @@ func (p *Provider) Register(a *Account) error {
if tos := ns.Link["terms-of-service"]; tos != "" {
r = &Registration{
Resource: ResReg,
- Contact: a.contact,
+ Contact: c,
Agreement: tos,
}
_, err = p.post(ns.Location.String(), a, r)