mirror of
				https://github.com/esphome/esphome.git
				synced 2025-11-04 00:51:49 +00:00 
			
		
		
		
	Apply suggestions from code review
This commit is contained in:
		@@ -2,6 +2,9 @@
 | 
				
			|||||||
#ifdef USE_ESP32
 | 
					#ifdef USE_ESP32
 | 
				
			||||||
#include "esphome/core/log.h"
 | 
					#include "esphome/core/log.h"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					#include <esp_heap_caps.h>
 | 
				
			||||||
 | 
					#include <esp_system.h>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#if defined(USE_ESP32_VARIANT_ESP32)
 | 
					#if defined(USE_ESP32_VARIANT_ESP32)
 | 
				
			||||||
#include <esp32/rom/rtc.h>
 | 
					#include <esp32/rom/rtc.h>
 | 
				
			||||||
#elif defined(USE_ESP32_VARIANT_ESP32C3)
 | 
					#elif defined(USE_ESP32_VARIANT_ESP32C3)
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -76,6 +76,7 @@ void DebugComponent::get_device_info_(std::string &device_info) {
 | 
				
			|||||||
void DebugComponent::update_platform_() {
 | 
					void DebugComponent::update_platform_() {
 | 
				
			||||||
#ifdef USE_SENSOR
 | 
					#ifdef USE_SENSOR
 | 
				
			||||||
  if (this->block_sensor_ != nullptr) {
 | 
					  if (this->block_sensor_ != nullptr) {
 | 
				
			||||||
 | 
					    // NOLINTNEXTLINE(readability-static-accessed-through-instance)
 | 
				
			||||||
    this->block_sensor_->publish_state(ESP.getMaxFreeBlockSize());
 | 
					    this->block_sensor_->publish_state(ESP.getMaxFreeBlockSize());
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
#if USE_ARDUINO_VERSION_CODE >= VERSION_CODE(2, 5, 2)
 | 
					#if USE_ARDUINO_VERSION_CODE >= VERSION_CODE(2, 5, 2)
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user