Changed endpoints and db queries, chart now shows suggested mins and maxes
This commit is contained in:
@@ -91,7 +91,7 @@ func sendLastSnapshot(w http.ResponseWriter, r *http.Request) {
|
||||
sendInternalError(fmt.Errorf("couldn't read last snapshot from the database: %w", err), w, r)
|
||||
return
|
||||
}
|
||||
json, err := createJsonFromSnapshotRecords(record)
|
||||
json, err := createJsonFromSnapshotRecords([]*SnapshotRecord{record})
|
||||
if err != nil {
|
||||
sendInternalError(fmt.Errorf("couldn't create a json from the last record: %w", err), w, r)
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user