Skip to content

Commit

Permalink
incorrectly named deepSleep sensor
Browse files Browse the repository at this point in the history
  • Loading branch information
itchannel committed Oct 22, 2023
1 parent 1921f31 commit 1c245bd
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions custom_components/fordpass/sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ def get_value(self, ftype):
return self.data.get("outsideTemperature", {}).get("value", "Unsupported")
if self.sensor == "engineOilTemp":
return self.data.get("engineOilTemp", {}).get("value", "Unsupported")
if self.sensor == "deepSleepInProgress":
if self.sensor == "deepSleep":
state = self.states.get("commandPreclusion", {}).get("value", {}).get("toState", "Unsupported")
if state == "COMMANDS_PRECLUDED":
return "ACTIVE"
Expand Down Expand Up @@ -207,8 +207,8 @@ def get_value(self, ftype):
return self.data.get("ignitionStatus", {})
if self.sensor == "firmwareUpgInProgress":
return self.data.get("firmwareUpgradeInProgress", {})
if self.sensor == "deepSleepInProgress":
return self.data.get("deepSleepInProgress", {})
if self.sensor == "deepSleep":
return None
if self.sensor == "doorStatus":
doors = {}
for value in self.data.get(self.sensor, []):
Expand Down

0 comments on commit 1c245bd

Please sign in to comment.