Skip to content

Commit

Permalink
Removed redundant parenthesis
Browse files Browse the repository at this point in the history
  • Loading branch information
willis89pr committed Dec 17, 2024
1 parent f9f0e2a commit a7ccf73
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions surfactant/infoextractors/js_file.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,7 @@ def extract_file_info(sbom: SBOM, software: Software, filename: str, filetype: s

def extract_js_info(filename: str) -> object:
js_info: Dict[str, Any] = {"jsLibraries": []}
js_lib_file = (
ConfigManager().get_data_dir_path() / "infoextractors" / "js_library_patterns.json"
)
js_lib_file = ConfigManager().get_data_dir_path() / "infoextractors" / "js_library_patterns.json"

# Load expressions from retire.js, should move this file elsewhere
try:
Expand Down Expand Up @@ -143,9 +141,7 @@ def load_db():
retirejs = load_database()
if retirejs is not None:
cleaned = strip_irrelevant_data(retirejs)
json_file_path = (
ConfigManager().get_data_dir_path() / "infoextractors" / "js_library_patterns.json"
)
json_file_path = ConfigManager().get_data_dir_path() / "infoextractors" / "js_library_patterns.json"
with open(json_file_path, "w") as f:
json.dump(cleaned, f, indent=4)
logger.info("Javascript library CVE database loaded.")
Expand Down

0 comments on commit a7ccf73

Please sign in to comment.