Skip to content

Commit 9f63165

Browse files
committed
Append bip32 derivations instead of replacing the map entirely
I guess this is a bit of an edge case, but in general I think it's always better to append metadata to a PSBT without removing what's already in there.
1 parent f46830c commit 9f63165

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/psbt/mod.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1264,7 +1264,7 @@ fn update_item_with_descriptor_helper<F: PsbtFields>(
12641264
}
12651265
}
12661266

1267-
*item.bip32_derivation() = bip32_derivation.0;
1267+
item.bip32_derivation().append(&mut bip32_derivation.0);
12681268

12691269
match &derived {
12701270
Descriptor::Bare(_) | Descriptor::Pkh(_) | Descriptor::Wpkh(_) => {}

0 commit comments

Comments
 (0)