hcl/ast: filter should compare value string
This commit is contained in:
parent
407a4ff94c
commit
eabb04dcd5
@ -61,7 +61,7 @@ func (o *ObjectList) Filter(keys ...string) *ObjectList {
|
|||||||
|
|
||||||
match := true
|
match := true
|
||||||
for i, key := range item.Keys[:len(keys)] {
|
for i, key := range item.Keys[:len(keys)] {
|
||||||
key := key.Token.Text
|
key := key.Token.Value().(string)
|
||||||
if key != keys[i] && !strings.EqualFold(key, keys[i]) {
|
if key != keys[i] && !strings.EqualFold(key, keys[i]) {
|
||||||
match = false
|
match = false
|
||||||
break
|
break
|
||||||
|
Loading…
Reference in New Issue
Block a user