Correct myUplink dash replacement (#111143)

* Corrected dash replacement

* Fix comment
This commit is contained in:
Åke Strandberg
2024-02-22 22:26:08 +01:00
committed by GitHub
parent 36c11119cf
commit 3be83bf2f5

View File

@@ -206,10 +206,8 @@ class MyUplinkDevicePointSensor(MyUplinkEntity, SensorEntity):
# Internal properties
self.point_id = device_point.parameter_id
# Remove soft hyphens and replace dash to hard hyphen
self._attr_name = device_point.parameter_name.replace("\u002d", "").replace(
"-", "\u2011"
)
# Remove soft hyphens
self._attr_name = device_point.parameter_name.replace("\u00ad", "")
if entity_description is not None:
self.entity_description = entity_description