Update EcowittExportCommand.php

//replace uvi empty values with 0
This commit is contained in:
David Blaik
2023-05-29 14:20:31 +10:00
committed by GitHub
parent 0fe6abf221
commit 9f3685349d

View File

@@ -124,6 +124,11 @@ class EcowittExportCommand extends Command
// uv // uv
$this->debug('collecting: uv'); $this->debug('collecting: uv');
$uvi = $this->getData($ecowitt, 'list.so_uv.list.uv'); $uvi = $this->getData($ecowitt, 'list.so_uv.list.uv');
//replace empty values with 0
foreach ($uvi as $key => $value) {
if(empty($value)) $uvi[$key] = "0";
}
// rainrate in mm/hr b // rainrate in mm/hr b
$this->debug('collecting: rainrate in mm/hr b'); $this->debug('collecting: rainrate in mm/hr b');