From 17f9774418d7ea8ad148df3ae2cb726183a9c852 Mon Sep 17 00:00:00 2001 From: Keith Burzinski Date: Sun, 21 Apr 2024 04:25:17 -0500 Subject: [PATCH] Fix esp32_ble_tracker --- .../esp32_ble_tracker/esp32_ble_tracker.cpp | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/esphome/components/esp32_ble_tracker/esp32_ble_tracker.cpp b/esphome/components/esp32_ble_tracker/esp32_ble_tracker.cpp index e102fe41c4..f6148a64f9 100644 --- a/esphome/components/esp32_ble_tracker/esp32_ble_tracker.cpp +++ b/esphome/components/esp32_ble_tracker/esp32_ble_tracker.cpp @@ -58,12 +58,11 @@ void ESP32BLETracker::setup() { this->scanner_idle_ = true; #ifdef USE_OTA - ota_esphome::global_ota_component->add_on_state_callback( - [this](ota_esphome::OTAESPHomeState state, float progress, uint8_t error) { - if (state == ota_esphome::OTA_STARTED) { - this->stop_scan(); - } - }); + esphome::global_ota_component->add_on_state_callback([this](ota::OTAState state, float progress, uint8_t error) { + if (state == ota::OTA_STARTED) { + this->stop_scan(); + } + }); #endif }