From 6cb3fad421ba99328617d0b349e1fb505f85d3cf Mon Sep 17 00:00:00 2001 From: ben-toogood Date: Fri, 31 Jul 2020 08:55:08 +0100 Subject: [PATCH] Fix proxy being overriden by default addresses (#1886) --- grpc.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/grpc.go b/grpc.go index 4ee1738..e2a0f9d 100644 --- a/grpc.go +++ b/grpc.go @@ -412,7 +412,7 @@ func (g *grpcClient) Call(ctx context.Context, req client.Request, rsp interface } // inject proxy address - if len(callOpts.Address) == 0 && len(g.opts.Proxy) > 0 { + if len(g.opts.Proxy) > 0 { callOpts.Address = []string{g.opts.Proxy} } @@ -520,7 +520,7 @@ func (g *grpcClient) Stream(ctx context.Context, req client.Request, opts ...cli } // inject proxy address - if len(callOpts.Address) == 0 && len(g.opts.Proxy) > 0 { + if len(g.opts.Proxy) > 0 { callOpts.Address = []string{g.opts.Proxy} }