diff --git a/pkg/sources/filesystem/filesystem.go b/pkg/sources/filesystem/filesystem.go index 01310f89bf6b..bee550a1d0c3 100644 --- a/pkg/sources/filesystem/filesystem.go +++ b/pkg/sources/filesystem/filesystem.go @@ -237,10 +237,7 @@ func (s *Source) Enumerate(ctx context.Context, reporter sources.UnitReporter) e } fullPath := filepath.Join(path, relativePath) item := sources.CommonSourceUnit{ID: fullPath} - if err := reporter.UnitOk(ctx, item); err != nil { - return err - } - return nil + return reporter.UnitOk(ctx, item) }) } item := sources.CommonSourceUnit{ID: path}