mirror of
https://github.com/andvikt/mega_hacs.git
synced 2025-12-12 01:24:29 +05:00
Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
1fd321d4c1 |
@@ -109,8 +109,9 @@ class MegaI2C(MegaPushEntity):
|
|||||||
def device_class(self):
|
def device_class(self):
|
||||||
return self._device_class
|
return self._device_class
|
||||||
|
|
||||||
|
@property
|
||||||
def state(self):
|
def state(self):
|
||||||
self.lg.debug(f'get % all states: %', self._params, self.mega.values)
|
# self.lg.debug(f'get % all states: %', self._params, self.mega.values)
|
||||||
return self.mega.values.get(self._params)
|
return self.mega.values.get(self._params)
|
||||||
|
|
||||||
@property
|
@property
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ class PriorityLock(asyncio.Lock):
|
|||||||
locked and returns True.
|
locked and returns True.
|
||||||
"""
|
"""
|
||||||
if (not self._locked and (self._waiters is None or
|
if (not self._locked and (self._waiters is None or
|
||||||
all(w.cancelled() for _, w in self._waiters))):
|
all(w.cancelled() for _, _, w in self._waiters))):
|
||||||
self._locked = True
|
self._locked = True
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user