mirror of
https://github.com/home-assistant/core.git
synced 2025-07-13 16:27:08 +00:00
Use new SwitchDeviceClass in aten_pe (#61281)
Co-authored-by: epenet <epenet@users.noreply.github.com>
This commit is contained in:
parent
fd7328ce23
commit
c893ad80e4
@ -6,8 +6,8 @@ from atenpdu import AtenPE, AtenPEError
|
||||
import voluptuous as vol
|
||||
|
||||
from homeassistant.components.switch import (
|
||||
DEVICE_CLASS_OUTLET,
|
||||
PLATFORM_SCHEMA,
|
||||
SwitchDeviceClass,
|
||||
SwitchEntity,
|
||||
)
|
||||
from homeassistant.const import CONF_HOST, CONF_PORT, CONF_USERNAME
|
||||
@ -67,7 +67,7 @@ async def async_setup_platform(hass, config, async_add_entities, discovery_info=
|
||||
class AtenSwitch(SwitchEntity):
|
||||
"""Represents an ATEN PE switch."""
|
||||
|
||||
_attr_device_class = DEVICE_CLASS_OUTLET
|
||||
_attr_device_class = SwitchDeviceClass.OUTLET
|
||||
|
||||
def __init__(self, device, mac, outlet, name):
|
||||
"""Initialize an ATEN PE switch."""
|
||||
|
Loading…
x
Reference in New Issue
Block a user