From 67740107936dc853183a8d8a22b3317ef6328f96 Mon Sep 17 00:00:00 2001 From: Szczepan Date: Tue, 24 Sep 2024 19:44:21 +0200 Subject: [PATCH] Fixed rssi --- components/wmbus/wmbus.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/wmbus/wmbus.cpp b/components/wmbus/wmbus.cpp index 2c178de..5326289 100755 --- a/components/wmbus/wmbus.cpp +++ b/components/wmbus/wmbus.cpp @@ -111,7 +111,7 @@ namespace wmbus { for (auto const& field : sensor->fields) { std::string field_name = field.first.first; std::string unit = field.first.second; - if (field.first == "rssi") { + if (field_name == "rssi") { field.second->publish_state(mbus_data.rssi); } else if (field.second->get_unit_of_measurement().empty()) {