Skip to content
This repository has been archived by the owner on Mar 27, 2024. It is now read-only.

feat: Add accept header in resolver http binding #1385

Merged
merged 1 commit into from Feb 27, 2020
Merged

feat: Add accept header in resolver http binding #1385

merged 1 commit into from Feb 27, 2020

Conversation

fqutishat
Copy link
Contributor

closes #1384

Signed-off-by: Firas Qutishat firas.qutishat@securekey.com

closes #1384

Signed-off-by: Firas Qutishat <firas.qutishat@securekey.com>
Comment on lines +20 to +22
const (
didLDJson = "application/did+ld+json"
)
Copy link
Contributor

@soluchok soluchok Feb 27, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: should be done in one line

if err != nil {
return nil, fmt.Errorf("HTTP Get request failed: %w", err)
}

defer closeResponseBody(resp.Body)

if resp.StatusCode == http.StatusOK {
var gotBody []byte
var gotBody []byte
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Redundant definition. Lint should not complain about gotBody, err :=

@llorllale llorllale merged commit 1994b00 into hyperledger-archives:master Feb 27, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Add accept header in resolver http binding
6 participants