1
0
mirror of https://github.com/esphome/esphome.git synced 2025-09-14 09:12:19 +01:00

remove safety check

This commit is contained in:
J. Nick Koston
2025-06-18 21:27:30 +02:00
parent 7dfdf965b7
commit 8002fe0dd5

View File

@@ -85,6 +85,7 @@ void ESPHomeOTAComponent::dump_config() {
void ESPHomeOTAComponent::loop() { void ESPHomeOTAComponent::loop() {
// Skip handle_() call if no client connected and no incoming connections // Skip handle_() call if no client connected and no incoming connections
// This optimization reduces idle loop overhead when OTA is not active // This optimization reduces idle loop overhead when OTA is not active
// Note: No need to check server_ for null as the component is marked failed in setup() if server_ creation fails
if (client_ != nullptr || server_->ready()) { if (client_ != nullptr || server_->ready()) {
this->handle_(); this->handle_();
} }