From a9e81e6c42d75602a77b2dee7b3fb0a0c26c3221 Mon Sep 17 00:00:00 2001 From: "J. Nick Koston" Date: Wed, 1 Apr 2026 00:31:31 -1000 Subject: [PATCH] =?UTF-8?q?Remove=20unnecessary=20nullptr=20guard=20?= =?UTF-8?q?=E2=80=94=20component=20is=20never=20null?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- esphome/core/component.cpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/esphome/core/component.cpp b/esphome/core/component.cpp index c7d0e15a3a0..955596ce956 100644 --- a/esphome/core/component.cpp +++ b/esphome/core/component.cpp @@ -521,8 +521,6 @@ WarnIfComponentBlockingGuard::warn_blocking(Component *component, uint32_t block #ifdef USE_RUNTIME_STATS void WarnIfComponentBlockingGuard::record_runtime_stats_() { - if (this->component_ == nullptr) - return; uint32_t duration_us = micros() - this->started_us_; this->component_->runtime_stats_.record_time(duration_us); }