mirror of
https://github.com/esphome/esphome.git
synced 2026-09-26 14:30:23 +00:00
[core] Inline set_component_state_ and use it in Application (#14369)
This commit is contained in:
@@ -297,10 +297,6 @@ void Component::mark_failed() {
|
||||
// Also remove from loop since failed components shouldn't loop
|
||||
App.disable_component_loop_(this);
|
||||
}
|
||||
void Component::set_component_state_(uint8_t state) {
|
||||
this->component_state_ &= ~COMPONENT_STATE_MASK;
|
||||
this->component_state_ |= state;
|
||||
}
|
||||
void Component::disable_loop() {
|
||||
if ((this->component_state_ & COMPONENT_STATE_MASK) != COMPONENT_STATE_LOOP_DONE) {
|
||||
ESP_LOGVV(TAG, "%s loop disabled", LOG_STR_ARG(this->get_component_log_str()));
|
||||
|
||||
Reference in New Issue
Block a user