diff --git a/database/src/main/java/info/nightscout/androidaps/database/transactions/SyncPumpExtendedBolusTransaction.kt b/database/src/main/java/info/nightscout/androidaps/database/transactions/SyncPumpExtendedBolusTransaction.kt index f3cd17eaa6..c90157c838 100644 --- a/database/src/main/java/info/nightscout/androidaps/database/transactions/SyncPumpExtendedBolusTransaction.kt +++ b/database/src/main/java/info/nightscout/androidaps/database/transactions/SyncPumpExtendedBolusTransaction.kt @@ -32,6 +32,7 @@ class SyncPumpExtendedBolusTransaction(private val extendedBolus: ExtendedBolus) val pctRun = (extendedBolus.timestamp - running.timestamp) / running.duration.toDouble() running.amount /= pctRun running.end = extendedBolus.timestamp + running.interfaceIDs.endId = extendedBolus.interfaceIDs.pumpId database.extendedBolusDao.updateExistingEntry(running) result.updated.add(running) } diff --git a/database/src/main/java/info/nightscout/androidaps/database/transactions/SyncPumpTemporaryBasalTransaction.kt b/database/src/main/java/info/nightscout/androidaps/database/transactions/SyncPumpTemporaryBasalTransaction.kt index bd4c64cf2d..e3303c5c90 100644 --- a/database/src/main/java/info/nightscout/androidaps/database/transactions/SyncPumpTemporaryBasalTransaction.kt +++ b/database/src/main/java/info/nightscout/androidaps/database/transactions/SyncPumpTemporaryBasalTransaction.kt @@ -35,6 +35,7 @@ class SyncPumpTemporaryBasalTransaction( val running = database.temporaryBasalDao.getTemporaryBasalActiveAt(temporaryBasal.timestamp, temporaryBasal.interfaceIDs.pumpType!!, temporaryBasal.interfaceIDs.pumpSerial!!).blockingGet() if (running != null) { running.end = temporaryBasal.timestamp + running.interfaceIDs.endId = temporaryBasal.interfaceIDs.pumpId database.temporaryBasalDao.updateExistingEntry(running) result.updated.add(running) }