From ebf56d00326b9b384ac05aaa431350c950bcc29e Mon Sep 17 00:00:00 2001 From: Milos Kozak Date: Mon, 3 Jul 2017 11:14:30 +0200 Subject: [PATCH] double check units are in profile --- .../main/java/info/nightscout/androidaps/data/Profile.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/app/src/main/java/info/nightscout/androidaps/data/Profile.java b/app/src/main/java/info/nightscout/androidaps/data/Profile.java index 6af7eed11e..dc49d95455 100644 --- a/app/src/main/java/info/nightscout/androidaps/data/Profile.java +++ b/app/src/main/java/info/nightscout/androidaps/data/Profile.java @@ -125,6 +125,12 @@ public class Profile { } public JSONObject getData() { + if (!json.has("units")) + try { + json.put("units", units); + } catch (JSONException e) { + e.printStackTrace(); + } return json; }