From a32be703f2776b07532c518292292a81cf9fec2f Mon Sep 17 00:00:00 2001 From: asychow Date: Mon, 11 Nov 2024 01:15:17 +0000 Subject: [PATCH] clean up --- hyundai_kia_connect_api/ApiImpl.py | 4 ++-- hyundai_kia_connect_api/VehicleManager.py | 12 ++++++------ 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/hyundai_kia_connect_api/ApiImpl.py b/hyundai_kia_connect_api/ApiImpl.py index c24b37ee..6aad1ce0 100644 --- a/hyundai_kia_connect_api/ApiImpl.py +++ b/hyundai_kia_connect_api/ApiImpl.py @@ -10,7 +10,7 @@ from requests.exceptions import JSONDecodeError from .Token import Token from .Vehicle import Vehicle -from .const import WINDOW_STATE, CHARGE_PORT_ACTION, OrderStatus, DOMAIN, VALET_MODE_ACTION +from .const import WINDOW_STATE, CHARGE_PORT_ACTION, OrderStatus, DOMAIN, VALET_MODE_ACTION, VEHICLE_LOCK_ACTION from .utils import get_child_value _LOGGER = logging.getLogger(__name__) @@ -128,7 +128,7 @@ def update_geocoded_location( get_child_value(response, "address"), ) - def lock_action(self, token: Token, vehicle: Vehicle, action: str) -> str: + def lock_action(self, token: Token, vehicle: Vehicle, action: VEHICLE_LOCK_ACTION) -> str: """Lock or unlocks a vehicle. Returns the tracking ID""" pass diff --git a/hyundai_kia_connect_api/VehicleManager.py b/hyundai_kia_connect_api/VehicleManager.py index 44a0eb9a..77b9b1ac 100644 --- a/hyundai_kia_connect_api/VehicleManager.py +++ b/hyundai_kia_connect_api/VehicleManager.py @@ -258,18 +258,18 @@ def enable_vehicle(self, vehicle_id: str) -> None: def schedule_charging_and_climate( self, vehicle_id: str, options: ScheduleChargingClimateRequestOptions - ) -> None: - self.api.schedule_charging_and_climate( + ) -> str: + return self.api.schedule_charging_and_climate( self.token, self.get_vehicle(vehicle_id), options ) - def start_valet_mode(self, vehicle_id: str) -> None: - self.api.valet_mode_action( + def start_valet_mode(self, vehicle_id: str) -> str: + return self.api.valet_mode_action( self.token, self.get_vehicle(vehicle_id), VALET_MODE_ACTION.ACTIVATE ) - def stop_valet_mode(self, vehicle_id: str) -> None: - self.api.valet_mode_action( + def stop_valet_mode(self, vehicle_id: str) -> str: + return self.api.valet_mode_action( self.token, self.get_vehicle(vehicle_id), VALET_MODE_ACTION.DEACTIVATE )