insert sent messages in Packet

This commit is contained in:
andrekir
2022-03-29 10:58:34 -03:00
parent 8de9a90c8f
commit 7c1c449dd3

View File

@@ -938,6 +938,16 @@ class MeshService : Service(), Logging {
p.time = System.currentTimeMillis() // update time to the actual time we started sending
// debug("Sending to radio: ${packet.toPIIString()}")
sendToRadio(packet)
if (packet.hasDecoded()) {
val packetToSave = Packet(
UUID.randomUUID().toString(),
"packet",
System.currentTimeMillis(),
packet.toString()
)
insertPacket(packetToSave)
}
}
private fun processQueuedPackets() {