aboutsummaryrefslogtreecommitdiffstats
path: root/bridge/github
diff options
context:
space:
mode:
authorrng-dynamics <73444470+rng-dynamics@users.noreply.github.com>2020-11-17 16:01:45 +0100
committerAlexander Scharinger <rng.dynamics@gmail.com>2020-11-18 09:18:32 +0100
commit09a845855f68f29db46e360380275471918f19c4 (patch)
tree7a29cb3ea6194cc62ae8997693468ecb3c268ce1 /bridge/github
parent1b889a91983598b99e2518543fe4b011b28fe074 (diff)
downloadgit-bug-09a845855f68f29db46e360380275471918f19c4.tar.gz
Apply suggestions from code review
Co-authored-by: Michael Muré <batolettre@gmail.com>
Diffstat (limited to 'bridge/github')
-rw-r--r--bridge/github/config.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/bridge/github/config.go b/bridge/github/config.go
index 2f9b8b0a..1f9cd384 100644
--- a/bridge/github/config.go
+++ b/bridge/github/config.go
@@ -216,7 +216,7 @@ func requestUserVerificationCode(scope string) (map[string]string, error) {
}
defer resp.Body.Close()
if resp.StatusCode != http.StatusOK {
- return nil, fmt.Errorf("unexpected response status code from Github API:", resp.StatusCode)
+ return nil, fmt.Errorf("unexpected response status code %d from Github API", resp.StatusCode)
}
data, err := ioutil.ReadAll(resp.Body)
if err != nil {
@@ -257,7 +257,7 @@ func pollGithubForAuthorization(deviceCode string, intervalSec int64) (string, e
}
defer resp.Body.Close()
if resp.StatusCode != http.StatusOK {
- return "", fmt.Errorf("unexpected response status code from Github API:", resp.StatusCode)
+ return "", fmt.Errorf("unexpected response status code %d from Github API", resp.StatusCode)
}
data, err := ioutil.ReadAll(resp.Body)
if err != nil {