@@ -99,8 +99,8 @@ enum GossipSourceConfig {
9999
100100#[ derive( Debug , Clone ) ]
101101struct LiquiditySourceConfig {
102- // LSPS2 service's (address, node_id , token)
103- lsps2_service : Option < ( SocketAddress , PublicKey , Option < String > ) > ,
102+ // LSPS2 service's (node_id, address , token)
103+ lsps2_service : Option < ( PublicKey , SocketAddress , Option < String > ) > ,
104104}
105105
106106impl Default for LiquiditySourceConfig {
@@ -330,14 +330,14 @@ impl NodeBuilder {
330330 ///
331331 /// The given `token` will be used by the LSP to authenticate the user.
332332 pub fn set_liquidity_source_lsps2 (
333- & mut self , address : SocketAddress , node_id : PublicKey , token : Option < String > ,
333+ & mut self , node_id : PublicKey , address : SocketAddress , token : Option < String > ,
334334 ) -> & mut Self {
335335 // Mark the LSP as trusted for 0conf
336336 self . config . trusted_peers_0conf . push ( node_id. clone ( ) ) ;
337337
338338 let liquidity_source_config =
339339 self . liquidity_source_config . get_or_insert ( LiquiditySourceConfig :: default ( ) ) ;
340- liquidity_source_config. lsps2_service = Some ( ( address , node_id , token) ) ;
340+ liquidity_source_config. lsps2_service = Some ( ( node_id , address , token) ) ;
341341 self
342342 }
343343
@@ -662,9 +662,9 @@ impl ArcedNodeBuilder {
662662 ///
663663 /// The given `token` will be used by the LSP to authenticate the user.
664664 pub fn set_liquidity_source_lsps2 (
665- & self , address : SocketAddress , node_id : PublicKey , token : Option < String > ,
665+ & self , node_id : PublicKey , address : SocketAddress , token : Option < String > ,
666666 ) {
667- self . inner . write ( ) . unwrap ( ) . set_liquidity_source_lsps2 ( address , node_id , token) ;
667+ self . inner . write ( ) . unwrap ( ) . set_liquidity_source_lsps2 ( node_id , address , token) ;
668668 }
669669
670670 /// Sets the used storage directory path.
@@ -1130,7 +1130,7 @@ fn build_with_store_internal(
11301130 } ;
11311131
11321132 let liquidity_source = liquidity_source_config. as_ref ( ) . and_then ( |lsc| {
1133- lsc. lsps2_service . as_ref ( ) . map ( |( address , node_id , token) | {
1133+ lsc. lsps2_service . as_ref ( ) . map ( |( node_id , address , token) | {
11341134 let lsps2_client_config = Some ( LSPS2ClientConfig { } ) ;
11351135 let liquidity_client_config =
11361136 Some ( LiquidityClientConfig { lsps1_client_config : None , lsps2_client_config } ) ;
@@ -1143,8 +1143,8 @@ fn build_with_store_internal(
11431143 liquidity_client_config,
11441144 ) ) ;
11451145 Arc :: new ( LiquiditySource :: new_lsps2 (
1146- address. clone ( ) ,
11471146 * node_id,
1147+ address. clone ( ) ,
11481148 token. clone ( ) ,
11491149 Arc :: clone ( & channel_manager) ,
11501150 Arc :: clone ( & keys_manager) ,
0 commit comments