mirror of
https://github.com/LukeHagar/libopenapi.git
synced 2025-12-07 04:20:14 +00:00
Signed-off-by: quobix <dave@quobix.com>
This commit is contained in:
@@ -236,6 +236,9 @@ func FindKeyNodeTop(key string, nodes []*yaml.Node) (keyNode *yaml.Node, valueNo
|
||||
}
|
||||
|
||||
if strings.EqualFold(key, v.Value) {
|
||||
if i+1 >= len(nodes) {
|
||||
return v, nodes[i]
|
||||
}
|
||||
return v, nodes[i+1] // next node is what we need.
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user