Skip to content

Commit

Permalink
[Modify] Fix Humidify+Cool missing fron airflow switch
Browse files Browse the repository at this point in the history
  • Loading branch information
shenxn committed Mar 15, 2021
1 parent 41c99c6 commit b38e9cb
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion custom_components/dyson_local/air_quality.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ async def async_setup_entry(
name = config_entry.data[CONF_NAME]
if isinstance(device, DysonPureCoolLink):
entities = [DysonPureCoolLinkAirQualityEntity(coordinator, device, name)]
else: # DysonPureCool
else: # DysonPureCool or DysonPureHumidifyCool
entities = [DysonPureCoolAirQualityEntity(coordinator, device, name)]
async_add_entities(entities)

Expand Down
4 changes: 2 additions & 2 deletions custom_components/dyson_local/switch.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

from typing import Callable

from libdyson import DysonPureCool
from libdyson import DysonPureCool, DysonPureHumidifyCool

from homeassistant.components.switch import SwitchEntity
from homeassistant.config_entries import ConfigEntry
Expand All @@ -24,7 +24,7 @@ async def async_setup_entry(
DysonContinuousMonitoringSwitchEntity(device, name),
DysonAutoModeSwitchEntity(device, name),
]
if isinstance(device, DysonPureCool):
if isinstance(device, DysonPureCool) or isinstance(device, DysonPureHumidifyCool):
entities.append(DysonFrontAirflowSwitchEntity(device, name))
async_add_entities(entities)

Expand Down

0 comments on commit b38e9cb

Please sign in to comment.