From f1e5096b7827d82ab5b2df10080a2ad9223f2665 Mon Sep 17 00:00:00 2001 From: jwijenbergh Date: Wed, 23 Mar 2022 16:41:15 +0100 Subject: Return headers in HTTP for wireguard expiry --- src/oauth.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/oauth.go') diff --git a/src/oauth.go b/src/oauth.go index eb93c00..f0d5b4a 100644 --- a/src/oauth.go +++ b/src/oauth.go @@ -123,7 +123,7 @@ func (oauth *OAuth) getTokensWithAuthCode(authCode string) error { "content-type": {"application/x-www-form-urlencoded"}} opts := &HTTPOptionalParams{Headers: headers, Body: data} current_time := generateTimeSeconds() - body, bodyErr := HTTPPostWithOpts(reqURL, opts) + _, body, bodyErr := HTTPPostWithOpts(reqURL, opts) if bodyErr != nil { return bodyErr } @@ -160,7 +160,7 @@ func (oauth *OAuth) getTokensWithRefresh() error { "content-type": {"application/x-www-form-urlencoded"}} opts := &HTTPOptionalParams{Headers: headers, Body: data} current_time := generateTimeSeconds() - body, bodyErr := HTTPPostWithOpts(reqURL, opts) + _, body, bodyErr := HTTPPostWithOpts(reqURL, opts) if bodyErr != nil { return bodyErr } -- cgit v1.2.3