Skip to content

Commit

Permalink
cuetil: Guard against empty values in AppendSplit
Browse files Browse the repository at this point in the history
  • Loading branch information
sam boyer committed May 15, 2023
1 parent e1d0481 commit 2165e14
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/cuetil/split.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import (
// Most calls to this should pass nil for the third parameter.
func AppendSplit(v cue.Value, splitBy cue.Op, a []cue.Value) []cue.Value {
if !v.Exists() {
return nil
return a
}
op, args := v.Expr()
// dedup elements.
Expand Down

0 comments on commit 2165e14

Please sign in to comment.