Skip to content

Commit

Permalink
chore: clean up false start
Browse files Browse the repository at this point in the history
Signed-off-by: Will Murphy <[email protected]>
  • Loading branch information
willmurphyscode committed Sep 18, 2024
1 parent ea816e4 commit 54b7100
Showing 1 changed file with 1 addition and 12 deletions.
13 changes: 1 addition & 12 deletions src/yardstick/capture.py
Original file line number Diff line number Diff line change
Expand Up @@ -122,18 +122,7 @@ def one(
if request.profile:
profile_obj = profiles.get(scan_config.tool_name, {}).get(request.profile, {})
if not profile_obj:
profile_obj = profiles.get(scan_config.tool_name.replace("-", "_"), {}).get(
request.profile, {}
)

if not profile_obj:
profile_obj = profiles.get(scan_config.tool_name.replace("_", "-"), {}).get(
request.profile, {}
)
if not profile_obj:
raise RuntimeError(
f"no profile found for tool {scan_config.tool_name} profile {request.profile}, have {profiles}"
)
raise RuntimeError(f"no profile found for tool {scan_config.tool_name}")

match_results, raw_json = run_scan(config=scan_config, profile=profile_obj)
store.scan_result.save(
Expand Down

0 comments on commit 54b7100

Please sign in to comment.