avoid warnings when no connection exists

feature/plugins-parameters
Geoff Whittington 2024-03-13 21:37:20 -04:00
rodzic 60e8dffbed
commit 2d331c201d
1 zmienionych plików z 4 dodań i 3 usunięć

Wyświetl plik

@ -70,9 +70,10 @@ async def main():
# Start the Matrix client
while True:
try:
# Update longnames & shortnames
update_longnames(meshtastic_interface.nodes)
update_shortnames(meshtastic_interface.nodes)
if meshtastic_interface:
# Update longnames & shortnames
update_longnames(meshtastic_interface.nodes)
update_shortnames(meshtastic_interface.nodes)
matrix_logger.info("Syncing with server...")
await matrix_client.sync_forever(timeout=30000)