diff --git a/main.go b/main.go index d2aee3c..9e77a36 100644 --- a/main.go +++ b/main.go @@ -153,6 +153,7 @@ munits: func treatFrames(frames chan []byte, client influxdb2.Client) { first := true writeAPI := client.WriteAPIBlocking("", "teleinfo/autogen") +fframe: for { frame := <-frames @@ -182,6 +183,9 @@ func treatFrames(frames chan []byte, client influxdb2.Client) { } if key == "DATE" { + if horodate == nil { + continue fframe + } defaultHorodate = *horodate continue }