@@ -735,6 +735,8 @@ where
735
735
& self , contents : T , destination : Destination , reply_path : Option < BlindedPath > ,
736
736
log_suffix : fmt:: Arguments
737
737
) -> Result < SendSuccess , SendError > {
738
+ let intro_node_logger =
739
+ WithContext :: from ( & self . logger , Some ( destination. first_node ( ) ) , None ) ;
738
740
let result = self . find_path ( destination)
739
741
. and_then ( |path| self . enqueue_onion_message ( path, contents, reply_path, log_suffix) ) ;
740
742
@@ -749,11 +751,11 @@ where
749
751
log_trace ! ( self . logger, "Failed sending onion message {}: {:?}" , log_suffix, e) ;
750
752
} ,
751
753
Ok ( SendSuccess :: Buffered ) => {
752
- log_trace ! ( self . logger , "Buffered onion message {}" , log_suffix) ;
754
+ log_trace ! ( intro_node_logger , "Buffered onion message {}" , log_suffix) ;
753
755
} ,
754
756
Ok ( SendSuccess :: BufferedAwaitingConnection ( node_id) ) => {
755
757
log_trace ! (
756
- WithContext :: from ( & self . logger , Some ( * node_id ) , None ) ,
758
+ intro_node_logger ,
757
759
"Buffered onion message waiting on peer connection {}: {}" ,
758
760
log_suffix, node_id
759
761
) ;
0 commit comments