From a7ccf73a9e0824c8fac22cacd6764050cbe5acf5 Mon Sep 17 00:00:00 2001 From: Willis Berrios Date: Tue, 17 Dec 2024 19:02:30 +0000 Subject: [PATCH] Removed redundant parenthesis --- surfactant/infoextractors/js_file.py | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/surfactant/infoextractors/js_file.py b/surfactant/infoextractors/js_file.py index 4fec9c75..ca073cff 100644 --- a/surfactant/infoextractors/js_file.py +++ b/surfactant/infoextractors/js_file.py @@ -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: @@ -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.")