mirror of
https://github.com/esphome/esphome.git
synced 2024-12-22 13:34:54 +01:00
Allow set climate preset to NONE (#5588)
This commit is contained in:
parent
84c00a5867
commit
b898f75631
1 changed files with 2 additions and 0 deletions
|
@ -213,6 +213,8 @@ ClimateCall &ClimateCall::set_preset(const std::string &preset) {
|
||||||
this->set_preset(CLIMATE_PRESET_SLEEP);
|
this->set_preset(CLIMATE_PRESET_SLEEP);
|
||||||
} else if (str_equals_case_insensitive(preset, "ACTIVITY")) {
|
} else if (str_equals_case_insensitive(preset, "ACTIVITY")) {
|
||||||
this->set_preset(CLIMATE_PRESET_ACTIVITY);
|
this->set_preset(CLIMATE_PRESET_ACTIVITY);
|
||||||
|
} else if (str_equals_case_insensitive(preset, "NONE")) {
|
||||||
|
this->set_preset(CLIMATE_PRESET_NONE);
|
||||||
} else {
|
} else {
|
||||||
if (this->parent_->get_traits().supports_custom_preset(preset)) {
|
if (this->parent_->get_traits().supports_custom_preset(preset)) {
|
||||||
this->custom_preset_ = preset;
|
this->custom_preset_ = preset;
|
||||||
|
|
Loading…
Reference in a new issue