mirror of
				https://github.com/esphome/esphome.git
				synced 2025-10-31 15:12:06 +00:00 
			
		
		
		
	Fix switch log state if inverted (#2960)
This commit is contained in:
		| @@ -34,7 +34,7 @@ void Switch::publish_state(bool state) { | |||||||
|   this->state = state != this->inverted_; |   this->state = state != this->inverted_; | ||||||
|  |  | ||||||
|   this->rtc_.save(&this->state); |   this->rtc_.save(&this->state); | ||||||
|   ESP_LOGD(TAG, "'%s': Sending state %s", this->name_.c_str(), ONOFF(state)); |   ESP_LOGD(TAG, "'%s': Sending state %s", this->name_.c_str(), ONOFF(this->state)); | ||||||
|   this->state_callback_.call(this->state); |   this->state_callback_.call(this->state); | ||||||
| } | } | ||||||
| bool Switch::assumed_state() { return false; } | bool Switch::assumed_state() { return false; } | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user