diff --git a/homeassistant/components/abode/binary_sensor.py b/homeassistant/components/abode/binary_sensor.py index c4cdadf9bd9..916ed2e2613 100644 --- a/homeassistant/components/abode/binary_sensor.py +++ b/homeassistant/components/abode/binary_sensor.py @@ -1,7 +1,10 @@ """Support for Abode Security System binary sensors.""" import abodepy.helpers.constants as CONST -from homeassistant.components.binary_sensor import BinarySensorDevice +from homeassistant.components.binary_sensor import ( + DEVICE_CLASS_WINDOW, + BinarySensorDevice, +) from . import AbodeDevice from .const import DOMAIN @@ -38,4 +41,6 @@ class AbodeBinarySensor(AbodeDevice, BinarySensorDevice): @property def device_class(self): """Return the class of the binary sensor.""" + if self._device.get_value("is_window") == "1": + return DEVICE_CLASS_WINDOW return self._device.generic_type