Fix callback and async (#31281)
* Fix callback and async * Fix a return * Fix test * Fix mqtt tests * Fix some more callbacks
This commit is contained in:
parent
ee602e40a6
commit
e9e44dbd97
90 changed files with 627 additions and 883 deletions
|
@ -2,6 +2,7 @@
|
|||
from homekit.model.characteristics import CharacteristicsTypes
|
||||
|
||||
from homeassistant.const import DEVICE_CLASS_BATTERY, TEMP_CELSIUS
|
||||
from homeassistant.core import callback
|
||||
|
||||
from . import KNOWN_DEVICES, HomeKitEntity
|
||||
|
||||
|
@ -246,6 +247,7 @@ async def async_setup_entry(hass, config_entry, async_add_entities):
|
|||
hkid = config_entry.data["AccessoryPairingID"]
|
||||
conn = hass.data[KNOWN_DEVICES][hkid]
|
||||
|
||||
@callback
|
||||
def async_add_service(aid, service):
|
||||
entity_class = ENTITY_TYPES.get(service["stype"])
|
||||
if not entity_class:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue