Skip to content

Commit

Permalink
Slider unavailable workaround (#328)
Browse files Browse the repository at this point in the history
* Slider unavailable workaround

@lbbrhzn not sure if this will help but as we push api changes turning off polling might help

* stet setting availability

* Init availability to True
  • Loading branch information
drc38 authored Jan 24, 2022
1 parent 6f9dba3 commit 1c6ea75
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions custom_components/ocpp/number.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,8 @@ def __init__(
self._attr_max_value = self.entity_description.max_value
self._attr_min_value = self.entity_description.min_value
self._attr_step = self.entity_description.step
self._attr_should_poll = False
self._attr_available = True

async def async_added_to_hass(self) -> None:
"""Handle entity which will be added."""
Expand Down

0 comments on commit 1c6ea75

Please sign in to comment.