Update v1_TeslaMateAPICarsDrives.go

Continuing updates on Drives API
This commit is contained in:
Alec O'Connor
2021-05-12 17:16:44 -04:00
committed by GitHub
parent ed1dc4dbb8
commit d65dff5aa3
+5
View File
@@ -229,6 +229,11 @@ func TeslaMateAPICarsDrivesV1(c *gin.Context) {
if err != nil {
log.Fatal(err)
}
// if no errors, but DrivesData is empty, return a valid response with an empty set
if len(DrivesData) == 0 {
ValidResponse = true
}
//
// build the data-blob