Skip to content

Commit

Permalink
chore: keep previous behavior for builtin/embeded checks
Browse files Browse the repository at this point in the history
  • Loading branch information
afdesk committed Feb 20, 2025
1 parent 5a82d13 commit b457d37
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/policy/policy.go
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,7 @@ func (p *Policies) scannerOptions(dataPaths []string, dataFS fs.FS, hasPolicies
rego.WithDataFilesystem(dataFS),
rego.WithDataDirs(dataPaths...),
}
if p.cac.GetUseEmbeddedRegoPolicies() {
if !hasPolicies && p.cac.GetUseEmbeddedRegoPolicies() {
return append(optionsArray, rego.WithEmbeddedPolicies(true), rego.WithEmbeddedLibraries(true))
}
return append(optionsArray,
Expand Down

0 comments on commit b457d37

Please sign in to comment.