Skip to content

Commit

Permalink
proxy: refactor a collapsible_match (#1214)
Browse files Browse the repository at this point in the history
  • Loading branch information
bishtpawan committed Mar 17, 2021
1 parent c666b29 commit 544282a
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/proxy.rs
Expand Up @@ -279,11 +279,8 @@ impl Proxy {
// Custom *may* match 'http', so assume so.
| Intercept::Custom(_) => true,
Intercept::System(ref system) => {
if let Some(proxy) = system.get("http") {
match proxy {
ProxyScheme::Http { auth, .. } => auth.is_some(),
_ => false,
}
if let Some(ProxyScheme::Http { auth, .. }) = system.get("http") {
auth.is_some()
} else {
false
}
Expand Down

0 comments on commit 544282a

Please sign in to comment.