@@ -642,7 +642,7 @@ impl Batcher {
642642 error ! ( "Failed to generate non paying data" ) ;
643643 send_message (
644644 ws_conn_sink. clone ( ) ,
645- SubmitProofResponseMessage :: NonPayingAddressError ,
645+ SubmitProofResponseMessage :: NonPayingNotAllowed ,
646646 )
647647 . await ;
648648 return Ok ( ( ) ) ;
@@ -1774,7 +1774,7 @@ impl Batcher {
17741774 info ! ( "Handling nonpaying message" ) ;
17751775 let Some ( non_paying_config) = self . non_paying_config . as_ref ( ) else {
17761776 warn ! ( "There isn't a non-paying configuration loaded. This message will be ignored" ) ;
1777- return Err ( TransactionSendError :: NonPayingAddressNotAllowed ) ;
1777+ return Err ( TransactionSendError :: NonPayingNotAllowed ) ;
17781778 } ;
17791779
17801780 let nonced_verification_data = NoncedVerificationData :: new (
@@ -1785,7 +1785,8 @@ impl Batcher {
17851785 self . payment_service . address ( ) ,
17861786 ) ;
17871787
1788- let client_msg = SubmitProofMessage :: new (
1788+ // We need to sign a message with the non-paying replacement address
1789+ let non_paying_replacement_msg = SubmitProofMessage :: new (
17891790 client_msg. verification_data . clone ( ) ,
17901791 non_paying_config. replacement . clone ( ) ,
17911792 )
@@ -1795,7 +1796,7 @@ impl Batcher {
17951796 Ok ( NonPayingData {
17961797 address : non_paying_config. replacement . address ( ) ,
17971798 nonced_verification_data,
1798- signature : client_msg . signature ,
1799+ signature : non_paying_replacement_msg . signature ,
17991800 } )
18001801 }
18011802
0 commit comments