Jelajahi Sumber

fix(glucoseformatter): mmol values now always showed with 1 decimal

Signed-off-by: Sjoerd Bozon <sjoerd.bozon@gmail.com>
Sjoerd Bozon 1 tahun lalu
induk
melakukan
80cdfdd2d2
1 mengubah file dengan 1 tambahan dan 0 penghapusan
  1. 1 0
      FreeAPS/Sources/Helpers/Formatters.swift

+ 1 - 0
FreeAPS/Sources/Helpers/Formatters.swift

@@ -63,6 +63,7 @@ extension Formatter {
 
 
         switch units {
         switch units {
         case .mmolL:
         case .mmolL:
+            formatter.minimumFractionDigits = 1
             formatter.maximumFractionDigits = 1
             formatter.maximumFractionDigits = 1
         case .mgdL:
         case .mgdL:
             formatter.maximumFractionDigits = 0
             formatter.maximumFractionDigits = 0