mirror of
https://github.com/home-assistant/core.git
synced 2025-07-21 12:17:07 +00:00
Use new enums in nuki (#61949)
This commit is contained in:
parent
c4c9dc8cee
commit
b3105dc218
@ -4,7 +4,10 @@ import logging
|
||||
|
||||
from pynuki import STATE_DOORSENSOR_OPENED
|
||||
|
||||
from homeassistant.components.binary_sensor import DEVICE_CLASS_DOOR, BinarySensorEntity
|
||||
from homeassistant.components.binary_sensor import (
|
||||
BinarySensorDeviceClass,
|
||||
BinarySensorEntity,
|
||||
)
|
||||
|
||||
from . import NukiEntity
|
||||
from .const import ATTR_NUKI_ID, DATA_COORDINATOR, DATA_LOCKS, DOMAIN as NUKI_DOMAIN
|
||||
@ -29,7 +32,7 @@ async def async_setup_entry(hass, entry, async_add_entities):
|
||||
class NukiDoorsensorEntity(NukiEntity, BinarySensorEntity):
|
||||
"""Representation of a Nuki Lock Doorsensor."""
|
||||
|
||||
_attr_device_class = DEVICE_CLASS_DOOR
|
||||
_attr_device_class = BinarySensorDeviceClass.DOOR
|
||||
|
||||
@property
|
||||
def name(self):
|
||||
|
Loading…
x
Reference in New Issue
Block a user