From 0a573bb60271de74cf6e5999823ae620cb25be2d Mon Sep 17 00:00:00 2001 From: rwalker777 <49888088+rwalker777@users.noreply.github.com> Date: Wed, 8 Apr 2026 15:39:09 -0500 Subject: [PATCH] Remove device class setting from sensor config Removed setting device class from sensor configuration if not specified. --- components/ups_hid/sensor.py | 3 --- 1 file changed, 3 deletions(-) diff --git a/components/ups_hid/sensor.py b/components/ups_hid/sensor.py index 816a460..a49736f 100644 --- a/components/ups_hid/sensor.py +++ b/components/ups_hid/sensor.py @@ -161,8 +161,5 @@ async def to_code(config): if "unit_of_measurement" not in config and "unit" in sensor_config: cg.add(var.set_unit_of_measurement(sensor_config["unit"])) - if "device_class" not in config and "device_class" in sensor_config: - cg.add(var.set_device_class(sensor_config["device_class"])) - if "accuracy_decimals" not in config and "accuracy_decimals" in sensor_config: cg.add(var.set_accuracy_decimals(sensor_config["accuracy_decimals"]))