Skip to content

Commit cdae14f

Browse files
committed
chore: clippy
1 parent 446b96e commit cdae14f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

iroh-relay/src/dns.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ impl DnsResolver {
141141
timeout: Duration,
142142
) -> Result<impl Iterator<Item = IpAddr>> {
143143
let addrs = time::timeout(timeout, self.0.lookup_ipv4(host.to_string())).await??;
144-
Ok(addrs.map(|ip| IpAddr::V4(ip)))
144+
Ok(addrs.map(IpAddr::V4))
145145
}
146146

147147
/// Performs an IPv6 lookup with a timeout.
@@ -151,7 +151,7 @@ impl DnsResolver {
151151
timeout: Duration,
152152
) -> Result<impl Iterator<Item = IpAddr>> {
153153
let addrs = time::timeout(timeout, self.0.lookup_ipv6(host.to_string())).await??;
154-
Ok(addrs.map(|ip| IpAddr::V6(ip)))
154+
Ok(addrs.map(IpAddr::V6))
155155
}
156156

157157
/// Resolves IPv4 and IPv6 in parallel with a timeout.

0 commit comments

Comments
 (0)