File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -261,8 +261,11 @@ impl SatsCard {
261261 }
262262 }
263263
264- // at this point pubkey must be available
265- let pubkey_bytes = dump_response. pubkey . unwrap ( ) ;
264+ // at this point the card is expected to include the pubkey; if not, treat it as sealed.
265+ let pubkey_bytes = match dump_response. pubkey {
266+ Some ( bytes) => bytes,
267+ None => return Err ( DumpError :: SlotSealed ( slot) ) ,
268+ } ;
266269 let pubkey = PublicKey :: from_slice ( & pubkey_bytes) ?;
267270
268271 // TODO use chaincode and master public key to verify pubkey or return error
@@ -456,6 +459,7 @@ impl core::fmt::Debug for SatsCard {
456459#[ cfg( feature = "emulator" ) ]
457460#[ cfg( test) ]
458461mod test {
462+ #![ allow( deprecated) ] // bdk_wallet::SignOptions is deprecated upstream; tests still rely on it.
459463 use crate :: CkTapCard ;
460464 use crate :: emulator:: find_emulator;
461465 use crate :: emulator:: test:: { CardTypeOption , EcardSubprocess } ;
You can’t perform that action at this time.
0 commit comments