]> Untitled Git - bdk-cli/commitdiff
fix: use flatten instead of filter_map()
authorDarthBenro008 <hkpdev008@gmail.com>
Thu, 15 Jul 2021 08:21:06 +0000 (13:51 +0530)
committerSteve Myers <steve@notmandatory.org>
Thu, 12 Aug 2021 12:56:31 +0000 (14:56 +0200)
Signed-off-by: DarthBenro008 <hkpdev008@gmail.com>
.github/workflows/cont_integration.yml
src/lib.rs

index 19e9fe6baac9023926cce233f0539c8d1a30646f..c0644c25bbcd3b0782633f1b6fc3e5b3f4d62413 100644 (file)
@@ -41,7 +41,7 @@ jobs:
           override: true
           components: rustfmt, clippy
       - name: Build
-        run: cargo build --features ${{ matrix.features }} --no-default-features
+        run: cargo build --features ${{ matrix.features }} --no-default-features --locked
       - name: Clippy
         run: cargo clippy -- -D warnings
       - name: Test
index 872cd9e2b289143eee1b9e796181c01d9e882065..7a3e55142324a82e8804a99653487044c46d7481 100644 (file)
@@ -750,7 +750,7 @@ where
                 internal_policy.map(|p| (p, KeychainKind::Internal)),
             ];
 
-            for (policy, keychain) in policies.into_iter().filter_map(|x| x) {
+            for (policy, keychain) in policies.into_iter().flatten() {
                 let policy = serde_json::from_str::<BTreeMap<String, Vec<usize>>>(&policy)
                     .map_err(|s| Error::Generic(s.to_string()))?;
                 tx_builder.policy_path(policy, keychain);