diff --git a/examples/companion_radio/ui-new/LiveShareScreen.h b/examples/companion_radio/ui-new/LiveShareScreen.h index 05897b01..83b33878 100644 --- a/examples/companion_radio/ui-new/LiveShareScreen.h +++ b/examples/companion_radio/ui-new/LiveShareScreen.h @@ -139,7 +139,10 @@ public: const uint8_t* pre = _prefs->favourite_contacts[i]; bool empty = true; for (int b = 0; b < NodePrefs::FAVOURITE_PREFIX_LEN; b++) if (pre[b]) { empty = false; break; } - if (empty || !the_mesh.lookupContactByPubKey(pre, NodePrefs::FAVOURITE_PREFIX_LEN)) continue; + ContactInfo* fc = the_mesh.lookupContactByPubKey(pre, NodePrefs::FAVOURITE_PREFIX_LEN); + // Skip room servers: a [LOC] DM to a room server isn't reposted to the + // room's members, so it can't serve as a live-share broadcast target. + if (empty || !fc || fc->type == ADV_TYPE_ROOM) continue; list[n].type = 1; list[n].ch = 0; memcpy(list[n].prefix, pre, NodePrefs::FAVOURITE_PREFIX_LEN); n++; } diff --git a/examples/companion_radio/ui-new/QuickMsgScreen.h b/examples/companion_radio/ui-new/QuickMsgScreen.h index ac6359ad..5bfcd323 100644 --- a/examples/companion_radio/ui-new/QuickMsgScreen.h +++ b/examples/companion_radio/ui-new/QuickMsgScreen.h @@ -908,6 +908,12 @@ public: } void commitPickTargetDM(const ContactInfo& ci) { + // A room server can't be a live-share target — a [LOC] DM to it is never + // reposted to the room's members. Reject the pick and keep the chooser open. + if (ci.type == ADV_TYPE_ROOM) { + _task->showAlert("Rooms not supported", 1400); + return; + } NodePrefs* p = _task->getNodePrefs(); if (p) { p->loc_share_target_type = 1;