Update dependencies (#5518)

This commit is contained in:
hongming
2023-02-12 23:09:20 +08:00
committed by GitHub
parent d3b35fb2da
commit a979342f56
1486 changed files with 126660 additions and 71128 deletions

View File

@@ -8,9 +8,9 @@ import (
"github.com/open-policy-agent/opa/ast"
)
func evalWalk(_ BuiltinContext, args []*ast.Term, iter func(*ast.Term) error) error {
input := args[0]
filter := getOutputPath(args)
func evalWalk(_ BuiltinContext, operands []*ast.Term, iter func(*ast.Term) error) error {
input := operands[0]
filter := getOutputPath(operands)
return walk(filter, nil, input, iter)
}
@@ -78,9 +78,9 @@ func pathAppend(path *ast.Array, key *ast.Term) *ast.Array {
return path.Append(key)
}
func getOutputPath(args []*ast.Term) *ast.Array {
if len(args) == 2 {
if arr, ok := args[1].Value.(*ast.Array); ok {
func getOutputPath(operands []*ast.Term) *ast.Array {
if len(operands) == 2 {
if arr, ok := operands[1].Value.(*ast.Array); ok {
if arr.Len() == 2 {
if path, ok := arr.Elem(0).Value.(*ast.Array); ok {
return path