Fix transport variable reference

This commit is contained in:
AZ Computer Guru
2025-12-28 12:44:28 -07:00
parent d2c8cf1c0b
commit d14fa5880f

View File

@@ -128,8 +128,13 @@ impl SessionManager {
tokio::time::sleep(Duration::from_millis(1)).await;
// Check if still connected
if !transport.is_connected() {
tracing::warn!("Connection lost");
if let Some(transport) = self.transport.as_ref() {
if !transport.is_connected() {
tracing::warn!("Connection lost");
break;
}
} else {
tracing::warn!("Transport is None");
break;
}
}