Skip to content

Commit

Permalink
Fix device_state_attributes warning
Browse files Browse the repository at this point in the history
  • Loading branch information
RogerSelwyn committed Dec 12, 2021
1 parent c57480f commit 4ba056b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion custom_components/o365/calendar.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ def __init__(self, hass, account, calendar_id, entity, entity_id):
self._data_attribute = []

@property
def device_state_attributes(self):
def extra_state_attributes(self):
"""Device state property."""
return {
"all_day": self._event.get("all_day", False) if self.data.event is not None else False,
Expand Down
4 changes: 2 additions & 2 deletions custom_components/o365/sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ def state(self):
return self._state

@property
def device_state_attributes(self):
def extra_state_attributes(self):
"""Device state attributes."""
return self._attributes

Expand Down Expand Up @@ -176,7 +176,7 @@ def state(self):
return self._state

@property
def device_state_attributes(self):
def extra_state_attributes(self):
"""Device state attributes."""
return self._attributes

Expand Down

0 comments on commit 4ba056b

Please sign in to comment.