Skip to content

Commit cc37d3f

Browse files
committed
CastToHttpProxy
1 parent 35470d5 commit cc37d3f

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

WebApiClient/ProxyValidator.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -177,8 +177,7 @@ private static HttpProxy CastToHttpProxy(IWebProxy webProxy, Uri targetAddress)
177177
throw new ArgumentNullException(nameof(targetAddress));
178178
}
179179

180-
var httpProxy = webProxy as HttpProxy;
181-
if (httpProxy != null)
180+
if (webProxy is HttpProxy httpProxy)
182181
{
183182
return httpProxy;
184183
}

0 commit comments

Comments
 (0)