From c4c61ec4bc0a6279e37c9aee0818db6ee8dfe666 Mon Sep 17 00:00:00 2001 From: Aliaksandr Pliutau Date: Thu, 1 Dec 2016 11:57:34 +0700 Subject: [PATCH] mocrofix --- client.go | 2 +- payment_test.go | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/client.go b/client.go index 1bd3e66..7dd8fb0 100644 --- a/client.go +++ b/client.go @@ -137,7 +137,7 @@ func (c *Client) log(r *http.Request, resp *http.Response) { reqDump := fmt.Sprintf("%s %s. Data: %s", r.Method, r.URL.String(), r.Form.Encode()) respDump, _ := httputil.DumpResponse(resp, true) - c.Log.Write([]byte("Request: " + string(reqDump) + "\nResponse: " + string(respDump) + "\n\n")) + c.Log.Write([]byte("Request: " + reqDump + "\nResponse: " + string(respDump) + "\n\n")) } } diff --git a/payment_test.go b/payment_test.go index 63699f6..b8007f4 100644 --- a/payment_test.go +++ b/payment_test.go @@ -2,11 +2,13 @@ package paypalsdk import ( "fmt" + "os" "testing" ) func TestCreateDirectPaypalPayment(t *testing.T) { c, _ := NewClient(testClientID, testSecret, APIBaseSandBox) + c.SetLog(os.Stdout) c.GetAccessToken() amount := Amount{