AUTH-1337: fix url path

This commit is contained in:
Austin Cherry 2019-01-24 14:42:13 -06:00
parent 2f59b8ac22
commit 9db4b7fdfb
1 changed files with 2 additions and 3 deletions

View File

@ -10,7 +10,6 @@ import (
"net/http"
"net/url"
"os"
"path/filepath"
"time"
"github.com/cloudflare/cloudflared/cmd/cloudflared/encrypter"
@ -52,7 +51,7 @@ func Run(transferURL *url.URL, resourceName, key, value, path string, shouldEncr
var resourceData []byte
if shouldEncrypt {
buf, key, err := transferRequest(baseStoreURL + filepath.Join("transfer", encrypterClient.PublicKey()))
buf, key, err := transferRequest(baseStoreURL + "transfer/" + encrypterClient.PublicKey())
if err != nil {
return nil, err
}
@ -68,7 +67,7 @@ func Run(transferURL *url.URL, resourceName, key, value, path string, shouldEncr
resourceData = decrypted
} else {
buf, _, err := transferRequest(baseStoreURL + filepath.Join(encrypterClient.PublicKey()))
buf, _, err := transferRequest(baseStoreURL + encrypterClient.PublicKey())
if err != nil {
return nil, err
}