fix(medtronic): regression in cannula change detection

it seems an erroneous `lastPrimeRecordTime!=0L && ` was added during the kotlin refactorings of this:
59a3bf8883 (diff-b3c8866292a4a902f69ba7dc1b82892bae6fc93a2dce97749c34f1fcf9f1f751R400)

this commit just reverts that line, which restores the previously-working functionality of automatic cannula change detection in medtronic pumps
This commit is contained in:
p5nbTgip0r 2022-05-20 06:31:25 -07:00
parent f845177c00
commit 66bc927fea

View file

@ -397,7 +397,7 @@ class MedtronicHistoryData @Inject constructor(
continue
}
if (primeRecord.atechDateTime > maxAllowedTimeInPast) {
if (lastPrimeRecordTime != 0L && lastPrimeRecordTime < primeRecord.atechDateTime) {
if (lastPrimeRecordTime < primeRecord.atechDateTime) {
lastPrimeRecordTime = primeRecord.atechDateTime
lastPrimeRecord = primeRecord
}