Moved from postfix to prefix on HA sensor name tag

This commit is contained in:
Gunnar Skjold
2023-04-01 07:38:24 +02:00
parent 71e0f13f0e
commit 81fedaaa6a
2 changed files with 5 additions and 5 deletions

View File

@@ -310,8 +310,8 @@ void HomeAssistantMqttHandler::publishSensor(const HomeAssistantSensor& sensor)
uid.replace("]", "");
uid.replace("'", "");
snprintf_P(json, BufferSize, HADISCOVER_JSON,
sensorNamePrefix.c_str(),
sensor.name,
sensorNamePostFix.c_str(),
topic.c_str(), sensor.topic,
deviceUid.c_str(), uid.c_str(),
deviceUid.c_str(), uid.c_str(),