sonar recommendations

This commit is contained in:
proddy
2022-03-05 16:21:00 +01:00
parent 10830dee36
commit d09e2237ee
20 changed files with 51 additions and 120 deletions

View File

@@ -85,7 +85,7 @@ class DallasSensor {
bool get_value_info(JsonObject & output, const char * cmd, const int8_t id);
// return back reference to the sensor list, used by other classes
const std::vector<Sensor> sensors() const {
std::vector<Sensor> sensors() const {
return sensors_;
}
@@ -102,7 +102,7 @@ class DallasSensor {
}
bool have_sensors() {
return (sensors_.size() > 0);
return (!sensors_.empty());
}
size_t no_sensors() {