Force braces around multi-line statements (#3094)

Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com>
This commit is contained in:
Oxan van LeeuwenandJesse Hills authored and GitHub committed 2022-01-25 08:56:36 +13:00
1 parent 6b27f2d2cf
commit 80d03a631e
125 files changed
+770 -504

No files matched your search

@@ -19,10 +19,11 @@ class ModbusBinarySensor : public Component, public binary_sensor::BinarySensor,
this->skip_updates = skip_updates;
this->force_new_range = force_new_range;
if (register_type == ModbusRegisterType::COIL || register_type == ModbusRegisterType::DISCRETE_INPUT)
if (register_type == ModbusRegisterType::COIL || register_type == ModbusRegisterType::DISCRETE_INPUT) {
this->register_count = offset + 1;
else
} else {
this->register_count = 1;
}
}
void parse_and_publish(const std::vector<uint8_t> &data) override;