Wear: fix crash

This commit is contained in:
Milos Kozak 2023-08-19 19:06:15 +02:00
parent ca25a337b5
commit aef65a2d17

View file

@ -901,7 +901,7 @@ class DataHandlerMobile @Inject constructor(
var cobString = ""
var currentBasal = ""
var bgiString = ""
if (profile != null) {
if (config.appInitialized && profile != null) {
val bolusIob = iobCobCalculator.calculateIobFromBolus().round()
val basalIob = iobCobCalculator.calculateIobFromTempBasalsIncludingConvertedExtended().round()
iobSum = DecimalFormatter.to2Decimal(bolusIob.iob + basalIob.basaliob)