From c4aab3fb5108d3352a3d234c7a676e9e32036b59 Mon Sep 17 00:00:00 2001 From: shangchenglumetro Date: Fri, 26 Jul 2024 02:37:13 +0900 Subject: [PATCH] chore: fix some comments (#3098) --- action.yml | 2 +- pkg/config/detectors.go | 2 +- pkg/sources/source_manager.go | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/action.yml b/action.yml index da93288a6..218c3ba53 100644 --- a/action.yml +++ b/action.yml @@ -43,7 +43,7 @@ runs: ## Scan by BASE & HEAD user inputs ## ## If BASE == HEAD, exit with error ## ########################################## - git status >/dev/null # make sure we are in a git repostiory + git status >/dev/null # make sure we are in a git repository if [ -n "$BASE" ] || [ -n "$HEAD" ]; then if [ -n "$BASE" ]; then base_commit=$(git rev-parse "$BASE" 2>/dev/null) || true diff --git a/pkg/config/detectors.go b/pkg/config/detectors.go index 3fcc226e0..d161d79bb 100644 --- a/pkg/config/detectors.go +++ b/pkg/config/detectors.go @@ -127,7 +127,7 @@ func (id DetectorID) String() string { return fmt.Sprintf("%s.v%d", name, id.Version) } -// allDetectors reutrns an ordered slice of all detector types. +// allDetectors returns an ordered slice of all detector types. func allDetectors() []DetectorID { all := make([]DetectorID, 0, len(dpb.DetectorType_name)) for id := range dpb.DetectorType_name { diff --git a/pkg/sources/source_manager.go b/pkg/sources/source_manager.go index e00626538..d3ba4a711 100644 --- a/pkg/sources/source_manager.go +++ b/pkg/sources/source_manager.go @@ -245,7 +245,7 @@ func (s *SourceManager) preflightChecks(ctx context.Context) error { return ctx.Err() } -// run is a helper method to sychronously run the source. It does not check for +// run is a helper method to synchronously run the source. It does not check for // acquired resources. An error is returned if there was a fatal error during // the run. This information is also recorded in the JobProgress. func (s *SourceManager) run(ctx context.Context, source Source, report *JobProgress, targets ...ChunkingTarget) error {