light: fix compile with ESP-IDF >= 5 (#4855)

This commit is contained in:
Stijn Tintel 2023-05-31 04:49:31 +03:00 committed by GitHub
parent 3ead48f0db
commit f9f335e692
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,3 +1,4 @@
#include <cinttypes>
#include "light_call.h"
#include "light_state.h"
#include "esphome/core/log.h"
@ -283,7 +284,7 @@ LightColorValues LightCall::validate_() {
// validate effect index
if (this->has_effect_() && *this->effect_ > this->parent_->effects_.size()) {
ESP_LOGW(TAG, "'%s' - Invalid effect index %u!", name, *this->effect_);
ESP_LOGW(TAG, "'%s' - Invalid effect index %" PRIu32 "!", name, *this->effect_);
this->effect_.reset();
}