Use new enums in hydrawise (#61781)
Co-authored-by: epenet <epenet@users.noreply.github.com>
This commit is contained in:
parent
a28ce75a92
commit
237a8a8331
3 changed files with 9 additions and 13 deletions
|
@ -6,9 +6,8 @@ import logging
|
|||
import voluptuous as vol
|
||||
|
||||
from homeassistant.components.binary_sensor import (
|
||||
DEVICE_CLASS_CONNECTIVITY,
|
||||
DEVICE_CLASS_MOISTURE,
|
||||
PLATFORM_SCHEMA,
|
||||
BinarySensorDeviceClass,
|
||||
BinarySensorEntity,
|
||||
BinarySensorEntityDescription,
|
||||
)
|
||||
|
@ -22,14 +21,14 @@ _LOGGER = logging.getLogger(__name__)
|
|||
BINARY_SENSOR_STATUS = BinarySensorEntityDescription(
|
||||
key="status",
|
||||
name="Status",
|
||||
device_class=DEVICE_CLASS_CONNECTIVITY,
|
||||
device_class=BinarySensorDeviceClass.CONNECTIVITY,
|
||||
)
|
||||
|
||||
BINARY_SENSOR_TYPES: tuple[BinarySensorEntityDescription, ...] = (
|
||||
BinarySensorEntityDescription(
|
||||
key="is_watering",
|
||||
name="Watering",
|
||||
device_class=DEVICE_CLASS_MOISTURE,
|
||||
device_class=BinarySensorDeviceClass.MOISTURE,
|
||||
),
|
||||
)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue