@@ -372,27 +372,8 @@ struct command_result *route_sendpay_request(struct command *cmd,
372372 assert (pinfo -> blinded_paths );
373373 const struct blinded_path * bpath =
374374 pinfo -> blinded_paths [route -> path_num ];
375+ json_myadd_blinded_path (req -> js , "blinded_path" , bpath );
375376
376- // FIXME: how can we support the case when the entry point is a
377- // scid?
378- assert (bpath -> first_node_id .is_pubkey );
379- json_object_start (req -> js , "blinded_path" );
380- json_add_pubkey (req -> js , "first_node_id" ,
381- & bpath -> first_node_id .pubkey );
382- json_add_pubkey (req -> js , "first_path_key" ,
383- & bpath -> first_path_key );
384- json_array_start (req -> js , "path" );
385- for (size_t i = 0 ; i < tal_count (bpath -> path ); i ++ ) {
386- const struct blinded_path_hop * hop = bpath -> path [i ];
387- json_object_start (req -> js , NULL );
388- json_add_pubkey (req -> js , "blinded_node_id" ,
389- & hop -> blinded_node_id );
390- json_add_hex_talarr (req -> js , "encrypted_recipient_data" ,
391- hop -> encrypted_recipient_data );
392- json_object_end (req -> js );
393- }
394- json_array_end (req -> js );
395- json_object_end (req -> js );
396377 }
397378
398379 route_map_add (payment -> routetracker -> sent_routes , route );
0 commit comments