From e37680af96f20d4995e918d84789f5f7d9aa4054 Mon Sep 17 00:00:00 2001 From: Steve Myers Date: Thu, 8 Apr 2021 13:37:59 -0700 Subject: [PATCH] Use .flatten() instead of .filter_map(|x| x), clippy warning https://rust-lang.github.io/rust-clippy/master/index.html#filter_map_identity --- src/descriptor/policy.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/descriptor/policy.rs b/src/descriptor/policy.rs index c8df81f5..f387fea8 100644 --- a/src/descriptor/policy.rs +++ b/src/descriptor/policy.rs @@ -870,7 +870,7 @@ impl ExtractPolicy for Miniscript .map(|n| n.extract_policy(signers, secp)) .collect::, _>>()? .into_iter() - .filter_map(|x| x) + .flatten() .collect(); if mapped.len() < nodes.len() {