explicitly initialize state

This commit is contained in:
Samuel Sieb 2024-11-23 22:35:50 -08:00
parent dcd3b1fa30
commit 0f6c798c42

View File

@ -58,7 +58,7 @@ class BinarySensor : public EntityBase, public EntityBase_DeviceClass {
void publish_initial_state(bool state); void publish_initial_state(bool state);
/// The current reported state of the binary sensor. /// The current reported state of the binary sensor.
bool state; bool state{false};
void add_filter(Filter *filter); void add_filter(Filter *filter);
void add_filters(const std::vector<Filter *> &filters); void add_filters(const std::vector<Filter *> &filters);