@@ -888,11 +888,16 @@ where
888888 }
889889
890890 fn handle_onion_message_response < T : OnionMessageContents > (
891- & self , response : ResponseInstruction < T > , log_suffix : fmt :: Arguments
891+ & self , response : ResponseInstruction < T > , message_type : & str , path_id : Option < [ u8 ; 32 ] >
892892 ) {
893893 if let ResponseInstruction :: WithoutReplyPath ( response) = response {
894894 let _ = self . find_path_and_enqueue_onion_message (
895- response. message , Destination :: BlindedPath ( response. reply_path ) , None , log_suffix
895+ response. message , Destination :: BlindedPath ( response. reply_path ) , None ,
896+ format_args ! (
897+ "when responding to {} onion message with path_id {:02x?}" ,
898+ message_type,
899+ path_id
900+ )
896901 ) ;
897902 }
898903 }
@@ -978,20 +983,12 @@ where
978983 ParsedOnionMessageContents :: Offers ( msg) => {
979984 let responder = reply_path. map ( |path| Responder :: new ( path) ) ;
980985 let response_instructions = self . offers_handler . handle_message ( msg, responder) ;
981- self . handle_onion_message_response ( response_instructions, format_args ! (
982- "when responding to {} onion message with path_id {:02x?}" ,
983- message_type,
984- path_id
985- ) )
986+ self . handle_onion_message_response ( response_instructions, message_type, path_id) ;
986987 } ,
987988 ParsedOnionMessageContents :: Custom ( msg) => {
988989 let responder = reply_path. map ( |path| Responder :: new ( path) ) ;
989990 let response_instructions = self . custom_handler . handle_custom_message ( msg, responder) ;
990- self . handle_onion_message_response ( response_instructions, format_args ! (
991- "when responding to {} onion message with path_id {:02x?}" ,
992- message_type,
993- path_id
994- ) )
991+ self . handle_onion_message_response ( response_instructions, message_type, path_id) ;
995992 } ,
996993 }
997994 } ,
0 commit comments