Fixed creation of candidateNode in operators to include file metadata

This commit is contained in:
Mike Farah
2021-02-11 10:58:40 +11:00
parent 49ac2bac13
commit 7518dac99c
19 changed files with 72 additions and 107 deletions
+1 -1
View File
@@ -26,7 +26,7 @@ func createBooleanCandidate(owner *CandidateNode, value bool) *CandidateNode {
valString = "false"
}
node := &yaml.Node{Kind: yaml.ScalarNode, Value: valString, Tag: "!!bool"}
return &CandidateNode{Node: node, Document: owner.Document, Path: owner.Path}
return owner.CreateChild(nil, node)
}
func nodeToMap(candidate *CandidateNode) *list.List {