Remove the GoCyclo append
as BuildStats already appends
This commit is contained in:
parent
b699340d13
commit
d3762b88e3
@ -22,7 +22,7 @@ func (Gocyclo) Desc() string {
|
|||||||
func (g Gocyclo) Run(ctx context.Context, lintCtx *Context) ([]result.Issue, error) {
|
func (g Gocyclo) Run(ctx context.Context, lintCtx *Context) ([]result.Issue, error) {
|
||||||
var stats []gocycloAPI.Stat
|
var stats []gocycloAPI.Stat
|
||||||
for _, f := range lintCtx.ASTCache.GetAllValidFiles() {
|
for _, f := range lintCtx.ASTCache.GetAllValidFiles() {
|
||||||
stats = append(stats, gocycloAPI.BuildStats(f.F, f.Fset, stats)...)
|
stats = gocycloAPI.BuildStats(f.F, f.Fset, stats)
|
||||||
}
|
}
|
||||||
if len(stats) == 0 {
|
if len(stats) == 0 {
|
||||||
return nil, nil
|
return nil, nil
|
||||||
|
Loading…
x
Reference in New Issue
Block a user