Skip to content

Commit

Permalink
fix min&max
Browse files Browse the repository at this point in the history
  • Loading branch information
mengjinglei committed Nov 21, 2015
1 parent 298b149 commit c94077e
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions tsdb/functions.go
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,15 @@ func InitializeUnmarshaller(c *influxql.Call) (UnmarshalFunc, error) {
err := json.Unmarshal(b, &o)
return &o, err
}, nil
case "min", "max":
return func(b []byte) (interface{}, error) {
if string(b) == "null" {
return nil, nil
}
var o minMaxMapOut
err := json.Unmarshal(b, &o)
return &o, err
}, nil
case "spread":
return func(b []byte) (interface{}, error) {
var o spreadMapOutput
Expand Down

0 comments on commit c94077e

Please sign in to comment.