mirror of
https://github.com/esphome/esphome.git
synced 2025-09-16 18:22:22 +01:00
Enable readability-redundant-member-init check (#3097)
This commit is contained in:
@@ -291,8 +291,7 @@ optional<float> FilterOutValueFilter::new_value(float value) {
|
||||
}
|
||||
|
||||
// ThrottleFilter
|
||||
ThrottleFilter::ThrottleFilter(uint32_t min_time_between_inputs)
|
||||
: Filter(), min_time_between_inputs_(min_time_between_inputs) {}
|
||||
ThrottleFilter::ThrottleFilter(uint32_t min_time_between_inputs) : min_time_between_inputs_(min_time_between_inputs) {}
|
||||
optional<float> ThrottleFilter::new_value(float value) {
|
||||
const uint32_t now = millis();
|
||||
if (this->last_input_ == 0 || now - this->last_input_ >= min_time_between_inputs_) {
|
||||
|
Reference in New Issue
Block a user