Skip to content
This repository has been archived by the owner on Nov 21, 2024. It is now read-only.

Commit

Permalink
Fix update arguments
Browse files Browse the repository at this point in the history
  • Loading branch information
jpkrajewski committed Sep 18, 2024
1 parent 310aabf commit 7c136e3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
9 changes: 4 additions & 5 deletions catalystwan/api/feature_profile_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -909,19 +909,18 @@ def get_parcel(
def update_parcel(
self,
profile_id: UUID,
parcel_type: Type[AnyServiceParcel],
parcel_id: UUID,
payload: AnyServiceParcel,
parcel_id: UUID,
vpn_uuid: Optional[UUID] = None,
) -> ParcelCreationResponse:
"""
Update Service Parcel for selected profile_id based on payload type
"""
if vpn_uuid is not None:
return self.endpoint.update_lan_vpn_sub_parcel(
profile_id, vpn_uuid, removeprefix(parcel_type._get_parcel_type(), "lan/vpn/"), parcel_id, payload
profile_id, vpn_uuid, removeprefix(payload._get_parcel_type(), "lan/vpn/"), parcel_id, payload
)
return self.endpoint.update(profile_id, parcel_type._get_parcel_type(), parcel_id, payload)
return self.endpoint.update(profile_id, payload._get_parcel_type(), parcel_id, payload)


class SystemFeatureProfileAPI:
Expand Down Expand Up @@ -1869,7 +1868,7 @@ def create_parcel(self, profile_id: UUID, config: ConfigParcel) -> ParcelCreatio
"""
return self.endpoint.create(profile_id, config)

def update_parcel(self, profile_id: UUID, parcel_id: UUID, config: ConfigParcel) -> ParcelCreationResponse:
def update_parcel(self, profile_id: UUID, config: ConfigParcel, parcel_id: UUID) -> ParcelCreationResponse:
"""
Update CLI Parcel for selected profile_id
"""
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "catalystwan"
version = "0.35.4dev2"
version = "0.35.4dev3"
description = "Cisco Catalyst WAN SDK for Python"
authors = ["kagorski <[email protected]>"]
readme = "README.md"
Expand Down

0 comments on commit 7c136e3

Please sign in to comment.