Skip to content

Commit

Permalink
fix(general): do not require a repo ID when using an API key and --li…
Browse files Browse the repository at this point in the history
…st (#5726)

do not require a repo ID when using an API key and --list
  • Loading branch information
mikeurbanski1 authored Nov 7, 2023
1 parent e11bc91 commit 1c788fb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion checkov/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ def normalize_config(self) -> None:
if self.config.use_enforcement_rules and not self.config.bc_api_key:
self.parser.error('Must specify an API key with --use-enforcement-rules')

if self.config.bc_api_key and not self.config.repo_id:
if self.config.bc_api_key and not self.config.repo_id and not self.config.list:
self.parser.error('--repo-id is required when using a platform API key')

if self.config.policy_metadata_filter and not (self.config.bc_api_key and self.config.prisma_api_url):
Expand Down

0 comments on commit 1c788fb

Please sign in to comment.