use ShouldBindJSON not ShouldBind
This commit is contained in:
parent
14d1dec45d
commit
484480348b
|
@ -21,7 +21,7 @@ func PushData(c *gin.Context) {
|
|||
|
||||
recvMetricValues := []*dataobj.MetricValue{}
|
||||
metricValues := []*dataobj.MetricValue{}
|
||||
errors.Dangerous(c.ShouldBind(&recvMetricValues))
|
||||
errors.Dangerous(c.ShouldBindJSON(&recvMetricValues))
|
||||
|
||||
var msg string
|
||||
for _, v := range recvMetricValues {
|
||||
|
|
Loading…
Reference in New Issue