PaesslerAG / jsonpath

BSD 3-Clause "New" or "Revised" License
172 stars 37 forks source link

bracket notation fixes #32

Closed rjbaucells closed 1 year ago

rjbaucells commented 1 year ago

Changes:

Bracket notation with number -1

test: negativ select array
path: $[-1]
data: [7, "hey"]
result: "hey"

Bracket notation with number -1 on empty array

test: negativ select on short array
path: $[-2]
data: [7]
result: nil

Bracket notation with number on short array

test: simple select out of bounds
path: $[1]
data: ["hey"]
result: nil
generikvault commented 1 year ago

thank you