diff --git a/app/src/main/java/info/nightscout/androidaps/plugins/Overview/Dialogs/NewCarbsDialog.java b/app/src/main/java/info/nightscout/androidaps/plugins/Overview/Dialogs/NewCarbsDialog.java index 5e2a811dbb..9ecf426a72 100644 --- a/app/src/main/java/info/nightscout/androidaps/plugins/Overview/Dialogs/NewCarbsDialog.java +++ b/app/src/main/java/info/nightscout/androidaps/plugins/Overview/Dialogs/NewCarbsDialog.java @@ -260,13 +260,9 @@ public class NewCarbsDialog extends DialogFragment implements OnClickListener, D Profile currentProfile = MainApp.getConfigBuilder().getProfile(); if(currentProfile == null) return; - if(currentProfile.getUnits().equals(Constants.MMOL)) { - esTT = eatingSoonTT > 0 ? Profile.toMgdl(eatingSoonTT,Constants.MMOL) : 90d; - activityTT = prefTT > 0 ? Profile.toMgdl(prefTT,Constants.MMOL) : 140d; - } else { - esTT = eatingSoonTT > 0 ? eatingSoonTT : 90d; - activityTT = prefTT > 0 ? prefTT : 140d; - } + + esTT = eatingSoonTT > 0 ? Profile.toMgdl(eatingSoonTT,currentProfile.getUnits()) : 90d; + activityTT = prefTT > 0 ? Profile.toMgdl(prefTT,currentProfile.getUnits()) : 140d; if (startActivityTTCheckbox.isChecked()) { if(currentProfile.getUnits().equals(Constants.MMOL)) {