display channel_echoes even if message is not decrypted if channel is configured (should not happen as there is no option not to decrypt messages ...)

This commit is contained in:
Florent 2026-03-23 18:50:01 -04:00
parent 86bcc900a9
commit 52cdaa2146

View file

@ -35,7 +35,7 @@ import re
from meshcore import MeshCore, EventType, logger
# Version
VERSION = "v1.5.1"
VERSION = "v1.5.2"
# default ble address is stored in a config file
MCCLI_CONFIG_DIR = str(Path.home()) + "/.config/meshcore/"
@ -237,13 +237,18 @@ async def handle_log_rx(event):
if payload_type == 0x05: # flood msg / channel
if handle_log_rx.channel_echoes:
chan_name = ""
if "message" in event.payload :
if "chan_name" in event.payload:
chan_name = event.payload["chan_name"]
else:
chan_name = ""
if "message" in event.payload :
message = event.payload["message"]
elif handle_log_rx.echo_unk_chans:
chan_name = event.payload["chan_hash"]
message = event.payload["crypted"]
elif handle_log_rx.echo_unk_chans or chan_name != "":
if chan_name == "":
chan_name = event.payload["chan_hash"]
if "crypted" in event.payload:
message = event.payload["crypted"]
if chan_name != "" :
width = os.get_terminal_size().columns