forked from TrueCloudLab/neoneo-go
rpcbroadcaster: don't mess with the URL from the config
It can be http://, it can be https://, it's not up to rpcbroadcaster to change it in any way.
This commit is contained in:
parent
87db4c9268
commit
863b9550e6
1 changed files with 2 additions and 2 deletions
|
@ -37,7 +37,7 @@ func (r *RPCBroadcaster) NewRPCClient(addr string, method SendMethod, timeout ti
|
|||
|
||||
func (c *RPCClient) run() {
|
||||
// We ignore error as not every node can be available on startup.
|
||||
c.client, _ = client.New(context.Background(), "http://"+c.addr, client.Options{
|
||||
c.client, _ = client.New(context.Background(), c.addr, client.Options{
|
||||
DialTimeout: c.sendTimeout,
|
||||
RequestTimeout: c.sendTimeout,
|
||||
})
|
||||
|
@ -48,7 +48,7 @@ func (c *RPCClient) run() {
|
|||
case ps := <-c.responses:
|
||||
if c.client == nil {
|
||||
var err error
|
||||
c.client, err = client.New(context.Background(), "http://"+c.addr, client.Options{
|
||||
c.client, err = client.New(context.Background(), c.addr, client.Options{
|
||||
DialTimeout: c.sendTimeout,
|
||||
RequestTimeout: c.sendTimeout,
|
||||
})
|
||||
|
|
Loading…
Reference in a new issue