Skip to content

Commit

Permalink
Fix empty methods
Browse files Browse the repository at this point in the history
  • Loading branch information
spacefreak86 committed Sep 6, 2023
1 parent e0c88ea commit de88ba8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/expr/functions/legendValue/function.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ func (f *legendValue) Do(ctx context.Context, e parser.Expr, from, until int32,
}

var system string
methods := make([]string, len(e.Args())-1)
var methods []string
for i := 1; i < len(e.Args()); i++ {
method, err := e.GetStringArg(i)
if err != nil {
Expand All @@ -47,7 +47,7 @@ func (f *legendValue) Do(ctx context.Context, e parser.Expr, from, until int32,
if method == "si" || method == "binary" {
system = method
} else {
methods[i-1] = method
methods = append(methods, method)
}
}

Expand Down

0 comments on commit de88ba8

Please sign in to comment.