Skip to content

Commit 61dfc61

Browse files
committed
f more context
1 parent b047c4c commit 61dfc61

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

lightning/src/onion_message/messenger.rs

+3-2
Original file line numberDiff line numberDiff line change
@@ -735,6 +735,7 @@ where
735735
&self, contents: T, destination: Destination, reply_path: Option<BlindedPath>,
736736
log_suffix: fmt::Arguments
737737
) -> Result<SendSuccess, SendError> {
738+
let intro_node_logger = WithContext::from(&self.logger, Some(path.first_node()), None);
738739
let result = self.find_path(destination)
739740
.and_then(|path| self.enqueue_onion_message(path, contents, reply_path, log_suffix));
740741

@@ -749,11 +750,11 @@ where
749750
log_trace!(self.logger, "Failed sending onion message {}: {:?}", log_suffix, e);
750751
},
751752
Ok(SendSuccess::Buffered) => {
752-
log_trace!(self.logger, "Buffered onion message {}", log_suffix);
753+
log_trace!(intro_node_logger, "Buffered onion message {}", log_suffix);
753754
},
754755
Ok(SendSuccess::BufferedAwaitingConnection(node_id)) => {
755756
log_trace!(
756-
WithContext::from(&self.logger, Some(*node_id), None),
757+
intro_node_logger,
757758
"Buffered onion message waiting on peer connection {}: {}",
758759
log_suffix, node_id
759760
);

0 commit comments

Comments
 (0)