Auto-favorite our node (#3609)

This commit is contained in:
Ben Meadors 2024-04-12 20:17:25 -05:00 committed by GitHub
parent 3f45c2d4f0
commit 2a6e26620e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -430,6 +430,8 @@ bool PhoneAPI::available()
auto nextNode = nodeDB->readNextMeshNode(readIndex);
if (nextNode) {
nodeInfoForPhone = TypeConversions::ConvertToNodeInfo(nextNode);
nodeInfoForPhone.is_favorite =
nodeInfoForPhone.is_favorite || nodeInfoForPhone.num == nodeDB->getNodeNum(); // Our node is always a favorite
}
}
return true; // Always say we have something, because we might need to advance our state machine