Skip to content

Commit

Permalink
fix(rego): skip optional policies in windows (#1529)
Browse files Browse the repository at this point in the history
  • Loading branch information
nikpivkin authored Jan 27, 2024
1 parent 60539be commit 150c886
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/rego/embed.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ func LoadPoliciesFromDirs(target fs.FS, paths ...string) (map[string]*ast.Module
return nil
}

if strings.HasSuffix(filepath.Dir(filepath.ToSlash(path)), "advanced/optional") {
if strings.HasSuffix(filepath.Dir(filepath.ToSlash(path)), filepath.Join("advanced", "optional")) {
return fs.SkipDir
}

Expand Down

0 comments on commit 150c886

Please sign in to comment.