@@ -67,7 +67,7 @@ use crate::wallet::{Wallet, WalletIo};
6767use crate :: { Namada , args, rpc} ;
6868
6969/// A structure holding the signing data to craft a transaction
70- #[ derive( Clone , PartialEq ) ]
70+ #[ derive( Clone , Debug , PartialEq ) ]
7171pub struct SigningTxData {
7272 /// The address owning the transaction
7373 pub owner : Option < Address > ,
@@ -84,7 +84,7 @@ pub struct SigningTxData {
8484}
8585
8686/// The fee's authorization
87- #[ derive( Clone ) ]
87+ #[ derive( Clone , Debug ) ]
8888pub enum FeeAuthorization {
8989 /// A wrapper signer
9090 Signer {
@@ -98,7 +98,7 @@ pub enum FeeAuthorization {
9898}
9999
100100/// A structure holding the signing data for a wrapper transaction
101- #[ derive( Clone ) ]
101+ #[ derive( Clone , Debug ) ]
102102pub struct SigningWrapperData {
103103 /// The signing data for each one of the inner transactions of this batch
104104 pub signing_data : Vec < SigningTxData > ,
@@ -131,7 +131,7 @@ impl SigningWrapperData {
131131}
132132
133133#[ allow( missing_docs) ]
134- #[ derive( Clone ) ]
134+ #[ derive( Clone , Debug ) ]
135135pub enum SigningData {
136136 Inner ( SigningTxData ) ,
137137 Wrapper ( SigningWrapperData ) ,
@@ -334,7 +334,7 @@ where
334334 let mut used_pubkeys = HashSet :: new ( ) ;
335335
336336 // First try to sign the raw header with the supplied signatures
337- let signatures = signing_tx_data
337+ let signatures: Vec < _ > = signing_tx_data
338338 . signatures
339339 . iter ( )
340340 . map ( |bytes| {
@@ -344,7 +344,9 @@ where
344344 sigidx
345345 } )
346346 . collect ( ) ;
347- tx. add_signatures ( signatures) ;
347+ if !signatures. is_empty ( ) {
348+ tx. add_signatures ( signatures) ;
349+ }
348350
349351 // Then try to sign the raw header with private keys in the software
350352 // wallet
0 commit comments