Honor parsed sequence indexes in version protections
This commit is contained in:
@@ -188,10 +188,10 @@ func fragmentVersionClaimProjected(root *document.Node, rule *VersionRule, sourc
|
||||
current = current.Mapping[index].Value
|
||||
currentPath = currentPath.Key(segment.key)
|
||||
case document.Sequence:
|
||||
if segment.kind != pathSegmentIndex {
|
||||
index, valid := schemaIndex(segment)
|
||||
if !valid {
|
||||
return current
|
||||
}
|
||||
index := segment.index
|
||||
for _, assigned := range ranges {
|
||||
if assigned.sourceIndex != sourceIndex || assigned.path.String() != currentPath.String() {
|
||||
continue
|
||||
|
||||
Reference in New Issue
Block a user