From 251889a9e2b7e5461ed1dc5c58fd31c5d8e5968c Mon Sep 17 00:00:00 2001 From: Stephen Tierney Date: Mon, 1 Feb 2021 22:45:09 +1100 Subject: [PATCH] Fix narrowing conversion --- esphome/components/ltr390/ltr390.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/esphome/components/ltr390/ltr390.cpp b/esphome/components/ltr390/ltr390.cpp index 1cf5c05ea9..2f766db637 100644 --- a/esphome/components/ltr390/ltr390.cpp +++ b/esphome/components/ltr390/ltr390.cpp @@ -137,7 +137,7 @@ void LTR390Component::read_mode_(int mode_index) { this->set_mode_(std::get<0>(this->mode_funcs_->at(mode_index))); // After the sensor integration time do the following - this->set_timeout(RESOLUTIONVALUE[this->res_] * 100, [this, mode_index]() { + this->set_timeout(((unsigned int) RESOLUTIONVALUE[this->res_]) * 100, [this, mode_index]() { // Read from the sensor std::get<1>(this->mode_funcs_->at(mode_index))();