Own node should be favorited and have zero hops away (#4618)

This commit is contained in:
Ben Meadors 2024-09-02 17:51:02 -05:00 committed by GitHub
parent 06e27bb6c2
commit b526a3ad53
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -194,6 +194,8 @@ size_t PhoneAPI::getFromRadio(uint8_t *buf)
auto us = nodeDB->readNextMeshNode(readIndex); auto us = nodeDB->readNextMeshNode(readIndex);
if (us) { if (us) {
nodeInfoForPhone = TypeConversions::ConvertToNodeInfo(us); nodeInfoForPhone = TypeConversions::ConvertToNodeInfo(us);
nodeInfoForPhone.hops_away = 0;
nodeInfoForPhone.is_favorite = true;
fromRadioScratch.which_payload_variant = meshtastic_FromRadio_node_info_tag; fromRadioScratch.which_payload_variant = meshtastic_FromRadio_node_info_tag;
fromRadioScratch.node_info = nodeInfoForPhone; fromRadioScratch.node_info = nodeInfoForPhone;
// Should allow us to resume sending NodeInfo in STATE_SEND_OTHER_NODEINFOS // Should allow us to resume sending NodeInfo in STATE_SEND_OTHER_NODEINFOS