Skip to content

Commit e185faa

Browse files
committed
display signature if contact unk
1 parent 53f89c8 commit e185faa

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/meshcore_cli/meshcore_cli.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,10 @@ async def process_event_message(mc, ev, json_output, end="\n", above=False):
116116
disp = disp + f"{name}"
117117
if 'signature' in data:
118118
sender = mc.get_contact_by_key_prefix(data['signature'])
119-
disp = disp + f"/{ANSI_BLUE}{sender['adv_name']}"
119+
if sender is None:
120+
disp = disp + f"/{ANSI_RED}{data['signature']}"
121+
else:
122+
disp = disp + f"/{ANSI_BLUE}{sender['adv_name']}"
120123
disp = disp + f" {ANSI_YELLOW}({path_str})"
121124
if data["txt_type"] == 1:
122125
disp = disp + f"{ANSI_LIGHT_GRAY}"

0 commit comments

Comments
 (0)