Reject a folder using the reference prefix, and filter bindings only where they exist
This commit is contained in:
committed by
lilleman-tw
parent
095a7f2de5
commit
2d8fcae4f4
@@ -55,6 +55,9 @@ func loadDir(dir string) (*group, error) {
|
||||
for _, e := range entries {
|
||||
full := filepath.Join(dir, e.Name())
|
||||
if e.IsDir() {
|
||||
if isRef(e.Name()) {
|
||||
return nil, fmt.Errorf("%s: folder %q starts with %q, which is reserved for {..path} bindings", full, e.Name(), refPrefix)
|
||||
}
|
||||
child, err := loadDir(full)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
|
||||
Reference in New Issue
Block a user