Skip to content

Commit

Permalink
Save nodedb after favoriting (or removing) (meshtastic#4537)
Browse files Browse the repository at this point in the history
  • Loading branch information
thebentern authored and geeksville committed Aug 28, 2024
1 parent e6163a5 commit 0617573
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/modules/AdminModule.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -238,6 +238,7 @@ bool AdminModule::handleReceivedProtobuf(const meshtastic_MeshPacket &mp, meshta
meshtastic_NodeInfoLite *node = nodeDB->getMeshNode(r->set_favorite_node);
if (node != NULL) {
node->is_favorite = true;
saveChanges(SEGMENT_DEVICESTATE, false);
}
break;
}
Expand All @@ -246,6 +247,7 @@ bool AdminModule::handleReceivedProtobuf(const meshtastic_MeshPacket &mp, meshta
meshtastic_NodeInfoLite *node = nodeDB->getMeshNode(r->remove_favorite_node);
if (node != NULL) {
node->is_favorite = false;
saveChanges(SEGMENT_DEVICESTATE, false);
}
break;
}
Expand Down

0 comments on commit 0617573

Please sign in to comment.