Skip to content

Commit

Permalink
normalize keyword check (#830)
Browse files Browse the repository at this point in the history
  • Loading branch information
zricethezav committed Apr 6, 2022
1 parent b0a958f commit c33ee3f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion detect/detect.go
Expand Up @@ -156,7 +156,8 @@ func (d *Detector) detectRule(fragment Fragment, rule *config.Rule) []report.Fin

containsKeyword := false
for _, k := range rule.Keywords {
if strings.Contains(fragment.Raw, k) {
if strings.Contains(strings.ToLower(fragment.Raw),
strings.ToLower(k)) {
containsKeyword = true
break
}
Expand Down

0 comments on commit c33ee3f

Please sign in to comment.