Jelajahi Sumber

Fix for delete ("-") button in Add Cabs View.
Clears to "0" when deleted.

Jon Mårtensson 3 tahun lalu
induk
melakukan
2937331b7f
1 mengubah file dengan 1 tambahan dan 1 penghapusan
  1. 1 1
      FreeAPS/Sources/Views/DecimalTextField.swift

+ 1 - 1
FreeAPS/Sources/Views/DecimalTextField.swift

@@ -67,7 +67,7 @@ struct DecimalTextField: UIViewRepresentable {
         let coordinator = context.coordinator
         let coordinator = context.coordinator
         if coordinator.isEditing {
         if coordinator.isEditing {
             coordinator.resetEditing()
             coordinator.resetEditing()
-        } else if value != 0 {
+        } else /* if value != 0 */ {
             textField.text = formatter.string(for: value)
             textField.text = formatter.string(for: value)
         }
         }
     }
     }