Fixing readonly ops not to modify context when paths dont exist

This commit is contained in:
Mike Farah
2021-05-16 14:17:13 +10:00
parent 3f51a44596
commit 0b71a40797
10 changed files with 88 additions and 26 deletions
+6
View File
@@ -60,3 +60,9 @@ func (n *Context) Clone() Context {
}
return clone
}
func (n *Context) ReadOnlyClone() Context {
clone := n.Clone()
clone.DontAutoCreate = true
return clone
}