fix mongodb no available sensors
This commit is contained in:
parent
5d60e0f53e
commit
169fd062ba
1 changed files with 1 additions and 1 deletions
|
@ -121,7 +121,7 @@ func (registry *mongodbSensorRegistry) GetSensors() ([]*WeatherSensor, error) {
|
|||
return nil, err
|
||||
}
|
||||
|
||||
var readData []*WeatherSensor
|
||||
var readData []*WeatherSensor = make([]*WeatherSensor, 0)
|
||||
if err = cursor.All(ctx, &readData); err != nil {
|
||||
log.Fatal(err)
|
||||
return nil, err
|
||||
|
|
Loading…
Add table
Reference in a new issue