Skip to content
This repository was archived by the owner on Mar 28, 2023. It is now read-only.

Commit 3a6184d

Browse files
authored
Merge pull request #1925 from OpenBazaar/brian.masterTransports
(#1861, 1862) Update vendored transports for Master
2 parents f349910 + 4b688cc commit 3a6184d

File tree

6 files changed

+32
-26
lines changed

6 files changed

+32
-26
lines changed

core/images.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ import (
99
_ "image/png"
1010
"io"
1111
"io/ioutil"
12-
"net"
1312
"net/http"
1413
netUrl "net/url"
1514
"os"
@@ -164,10 +163,9 @@ func (n *OpenBazaarNode) FetchImage(peerID string, imageType string, size string
164163

165164
// GetBase64Image - fetch the image and return it as base64 encoded string
166165
func (n *OpenBazaarNode) GetBase64Image(url string) (base64ImageData, filename string, err error) {
167-
dial := net.Dial
168166
var client *http.Client
169167
if n.TorDialer != nil {
170-
dial = n.TorDialer.Dial
168+
dial := n.TorDialer.Dial
171169
tbTransport := &http.Transport{Dial: dial}
172170
client = &http.Client{Transport: tbTransport, Timeout: time.Second * 30}
173171
} else {

net/retriever/retriever.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ import (
1313
"gx/ipfs/QmerPMzPk1mJVowm8KgmoknWa4yCYvvugMPsgWmDNUvDLW/go-multihash"
1414

1515
"io/ioutil"
16-
gonet "net"
1716
"net/http"
1817
"sync"
1918
"time"
@@ -68,10 +67,9 @@ type offlineMessage struct {
6867
}
6968

7069
func NewMessageRetriever(cfg MRConfig) *MessageRetriever {
71-
dial := gonet.Dial
7270
var client *http.Client
7371
if cfg.Dialer != nil {
74-
dial = cfg.Dialer.Dial
72+
dial := cfg.Dialer.Dial
7573
tbTransport := &http.Transport{Dial: dial}
7674
client = &http.Client{Transport: tbTransport, Timeout: time.Second * 30}
7775
} else {

vendor/github.com/OpenBazaar/multiwallet/bitcoincash/exchange_rates.go

Lines changed: 7 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/github.com/OpenBazaar/multiwallet/client/blockbook/client.go

Lines changed: 9 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/github.com/OpenBazaar/multiwallet/litecoin/exchange_rates.go

Lines changed: 7 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/github.com/OpenBazaar/multiwallet/zcash/exchange_rates.go

Lines changed: 7 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)