Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 40d23ed

Browse files
committed
Directly check that http2Transport != nil
1 parent da97a9c commit 40d23ed

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

dnscrypt-proxy/xtransport.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,7 @@ func (xTransport *XTransport) rebuildTransport() {
281281
}
282282
}
283283
transport.TLSClientConfig = &tlsClientConfig
284-
if http2Transport, err := http2.ConfigureTransports(transport); err == nil {
284+
if http2Transport, _ := http2.ConfigureTransports(transport); http2Transport == nil {
285285
http2Transport.ReadIdleTimeout = timeout
286286
http2Transport.AllowHTTP = false
287287
}

0 commit comments

Comments
 (0)