Added error for invalid checks

This commit is contained in:
Anton Ritter-Gogerly 2021-07-13 18:39:19 +10:00 committed by Naveen
parent 219404e0b7
commit 0967915691

View File

@ -120,6 +120,8 @@ or ./scorecard --{npm,pypi,rubgems}=<package_name> [--checks=check1,...] [--show
for _, checkToRun := range checksToRun {
if checkFn, ok := checks.AllChecks[checkToRun]; ok {
enabledChecks[checkToRun] = checkFn
} else {
log.Fatalf("Invalid check: %s", checkToRun)
}
}
} else {