This commit is contained in:
Johannes Mockenhaupt 2018-03-23 23:14:15 +01:00
parent 8a7776fd74
commit a4e9cb4976
No known key found for this signature in database
GPG key ID: 9E1EA6AF7BBBB0D1
2 changed files with 2 additions and 2 deletions

View file

@ -162,7 +162,7 @@ public class NewInsulinDialog extends DialogFragment implements OnClickListener,
private String toSignedString(double value) {
String formatted = DecimalFormatter.toPumpSupportedBolus(value);
return value < 0 ? "-" + formatted : formatted;
return value > 0 ? "+" + formatted : formatted;
}
@Override

View file

@ -179,7 +179,7 @@ public class NSUpload {
DbLogger.dbAdd(intent, data.toString());
}
private static String getNextAvailableSecond(long time) {
private static synchronized String getNextAvailableSecond(long time) {
long second = time - time % 1000;
if (second == lastUsedSecond) second += 1000;
lastUsedSecond = second;