Skip to content

Commit

Permalink
fix: typo function name and comment optimization (#6200)
Browse files Browse the repository at this point in the history
Signed-off-by: guoguangwu <guoguangwu@magic-shield.com>
  • Loading branch information
testwill committed Mar 4, 2024
1 parent c4b5ab7 commit 3d2f583
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions pkg/k8s/k8s.go
Expand Up @@ -28,12 +28,12 @@ func NewScanKubernetes(s local.Scanner) *ScanKubernetes {
return &ScanKubernetes{localScanner: s}
}

// NewKubenetesScanner is the factory method for scanner
func NewKubenetesScanner() *ScanKubernetes {
// NewKubernetesScanner is the factory method for scanner
func NewKubernetesScanner() *ScanKubernetes {
return initializeScanK8s(nil)
}

// // Scan scans k8s core components and return it findings
// Scan scans k8s core components and return it findings
func (sk ScanKubernetes) Scan(ctx context.Context, target types.ScanTarget, options types.ScanOptions) (types.Results, ftypes.OS, error) {
return sk.localScanner.ScanTarget(ctx, target, options)
}
2 changes: 1 addition & 1 deletion pkg/k8s/scanner/scanner.go
Expand Up @@ -229,7 +229,7 @@ func (s *Scanner) scanK8sVulns(ctx context.Context, artifactsData []*artifacts.A
return resources, nil
}

k8sScanner := k8s.NewKubenetesScanner()
k8sScanner := k8s.NewKubernetesScanner()
scanOptions := types.ScanOptions{
Scanners: s.opts.Scanners,
VulnType: s.opts.VulnType,
Expand Down

0 comments on commit 3d2f583

Please sign in to comment.