diff --git a/custom_components/myskoda/sensor.py b/custom_components/myskoda/sensor.py index 15b4810..d6184b5 100644 --- a/custom_components/myskoda/sensor.py +++ b/custom_components/myskoda/sensor.py @@ -250,7 +250,8 @@ class ChargeType(ChargingSensor): @property def native_value(self) -> str | None: # noqa: D102 if status := self._status(): - return str(status.charge_type).lower() + if status.charge_type: + return str(status.charge_type).lower() class ChargingState(ChargingSensor): diff --git a/custom_components/myskoda/translations/en.json b/custom_components/myskoda/translations/en.json index e52d06f..962f2f6 100644 --- a/custom_components/myskoda/translations/en.json +++ b/custom_components/myskoda/translations/en.json @@ -99,7 +99,12 @@ "name": "Mileage" }, "charge_type": { - "name": "Charge Type" + "name": "Charge Type", + "state": { + "ac": "AC", + "dc": "DC", + "off": "OFF" + } }, "remaining_charging_time": { "name": "Remaining Charging Time"