fix: Default value to 0.0F instead of null

Bu işleme şunda yer alıyor:
Jean-Remy Hok 2022-01-11 15:43:36 +01:00
ebeveyn 9c04f6c9fd
işleme 9c20191206
4 değiştirilmiş dosya ile 4 ekleme ve 4 silme

Dosyayı Görüntüle

@ -29,7 +29,7 @@ public class Co2SensorController {
@PostMapping("/") @PostMapping("/")
public int addSensor() { public int addSensor() {
sensorValues.put(currentMaxId, null); sensorValues.put(currentMaxId, 0.0F);
return currentMaxId++; return currentMaxId++;
} }

Dosyayı Görüntüle

@ -29,7 +29,7 @@ public class GazSensorController {
@PostMapping("/") @PostMapping("/")
public int addSensor() { public int addSensor() {
sensorValues.put(currentMaxId, null); sensorValues.put(currentMaxId, 0.0F);
return currentMaxId++; return currentMaxId++;
} }

Dosyayı Görüntüle

@ -29,7 +29,7 @@ public class LightSensorController {
@PostMapping("/") @PostMapping("/")
public int addSensor() { public int addSensor() {
sensorValues.put(currentMaxId, null); sensorValues.put(currentMaxId, 0.0F);
return currentMaxId++; return currentMaxId++;
} }

Dosyayı Görüntüle

@ -29,7 +29,7 @@ public class TemperatureSensorController {
@PostMapping("/") @PostMapping("/")
public int addSensor() { public int addSensor() {
sensorValues.put(currentMaxId, null); sensorValues.put(currentMaxId, 0.0F);
return currentMaxId++; return currentMaxId++;
} }