Skip to content

Commit 0f3394e

Browse files
authored
Fix for the validation test being in the get instead of post (#24)
* Fix for the validation test being in the get instead of post
1 parent fc24237 commit 0f3394e

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

socketdev/fullscans/__init__.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -709,8 +709,6 @@ def create_params_string(self, params: dict) -> str:
709709

710710
def get(self, org_slug: str, params: dict, use_types: bool = False) -> Union[dict, GetFullScanMetadataResponse]:
711711
params_arg = self.create_params_string(params)
712-
Utils.validate_integration_type(params.get("integration_type", ""))
713-
714712
path = "orgs/" + org_slug + "/full-scans" + str(params_arg)
715713
response = self.api.do_request(path=path)
716714

@@ -729,9 +727,11 @@ def get(self, org_slug: str, params: dict, use_types: bool = False) -> Union[dic
729727
return {}
730728

731729
def post(self, files: list, params: FullScanParams, use_types: bool = False) -> Union[dict, CreateFullScanResponse]:
730+
Utils.validate_integration_type(params.integration_type if params.integration_type else "api")
732731
org_slug = str(params.org_slug)
733732
params_dict = params.to_dict()
734733
params_dict.pop("org_slug")
734+
735735
params_arg = self.create_params_string(params_dict)
736736

737737
path = "orgs/" + org_slug + "/full-scans" + str(params_arg)

socketdev/version.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__version__ = "2.0.8"
1+
__version__ = "2.0.9"

0 commit comments

Comments
 (0)