We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b01f49e commit 4fda076Copy full SHA for 4fda076
analyzer.go
@@ -543,8 +543,7 @@ func (gosec *Analyzer) ParseErrors(pkg *packages.Package) error {
543
// AppendError appends an error to the file errors
544
func (gosec *Analyzer) AppendError(file string, err error) {
545
// Do not report the error for empty packages (e.g. files excluded from build with a tag)
546
- r := regexp.MustCompile(`no buildable Go source files in`)
547
- if r.MatchString(err.Error()) {
+ if strings.Contains(err.Error(), "no buildable Go source files in") {
548
return
549
}
550
errors := make([]Error, 0)
0 commit comments