diff --git a/app/src/main/java/info/nightscout/androidaps/db/CareportalEvent.java b/app/src/main/java/info/nightscout/androidaps/db/CareportalEvent.java index 7302475a4e..b0f69144c5 100644 --- a/app/src/main/java/info/nightscout/androidaps/db/CareportalEvent.java +++ b/app/src/main/java/info/nightscout/androidaps/db/CareportalEvent.java @@ -98,9 +98,9 @@ public class CareportalEvent implements DataPointWithLabelInterface { return diff.get(TimeUnit.DAYS) + " " + MainApp.sResources.getString(R.string.days) + " " + diff.get(TimeUnit.HOURS) + " " + MainApp.sResources.getString(R.string.hours); } - public boolean isOlderThan(double days) { + public boolean isOlderThan(double hours) { Map diff = computeDiff(date, System.currentTimeMillis()); - if(diff.get(TimeUnit.DAYS) > days) + if(diff.get(TimeUnit.DAYS)*24 + diff.get(TimeUnit.HOURS) > hours) return true; else return false;