mirror of
https://github.com/andvikt/mega_hacs.git
synced 2026-11-04 11:58:45 +05:00
small bugfix
This commit is contained in:
1 parent
2a0f60f1b2
commit
2a4a85a20e
1 file changed
+4
-1
@@ -41,7 +41,10 @@ class BaseMegaEntity(CoordinatorEntity, RestoreEntity):
|
|||||||
if self.hass is None:
|
if self.hass is None:
|
||||||
return {}
|
return {}
|
||||||
if self._customize is None:
|
if self._customize is None:
|
||||||
self._customize = self.hass.data.get(DOMAIN, {}).get(CONF_CUSTOM, {}).get(self._mega_id).get(self.port, {})
|
c = self.hass.data.get(DOMAIN, {}).get(CONF_CUSTOM) or {}
|
||||||
|
c = c.get(self._mega_id) or {}
|
||||||
|
c = c.get(self.port) or {}
|
||||||
|
self._customize = c
|
||||||
return self._customize
|
return self._customize
|
||||||
|
|
||||||
@property
|
@property
|
||||||
|
|||||||
Reference in new issue
Block a user