Add hass property to Entity to prevent 'Attribute hass is None' error during self.update_ha_state
This commit is contained in:
parent
ce22f3c82d
commit
d4834ff408
1 changed files with 1 additions and 0 deletions
|
@ -57,6 +57,7 @@ class SonosDevice(MediaPlayerDevice):
|
||||||
|
|
||||||
# pylint: disable=too-many-arguments
|
# pylint: disable=too-many-arguments
|
||||||
def __init__(self, hass, player):
|
def __init__(self, hass, player):
|
||||||
|
self.hass = hass
|
||||||
super(SonosDevice, self).__init__()
|
super(SonosDevice, self).__init__()
|
||||||
self._player = player
|
self._player = player
|
||||||
self.update()
|
self.update()
|
||||||
|
|
Loading…
Add table
Reference in a new issue