Fix shelly RSSI sensor unit (#49265)

pull/49271/head
Shay Levy 2021-04-15 20:52:06 +03:00 committed by GitHub
parent 80f66f301b
commit 31c519b26d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -9,7 +9,7 @@ from homeassistant.const import (
LIGHT_LUX,
PERCENTAGE,
POWER_WATT,
SIGNAL_STRENGTH_DECIBELS,
SIGNAL_STRENGTH_DECIBELS_MILLIWATT,
VOLT,
)
@ -178,7 +178,7 @@ SENSORS = {
REST_SENSORS = {
"rssi": RestAttributeDescription(
name="RSSI",
unit=SIGNAL_STRENGTH_DECIBELS,
unit=SIGNAL_STRENGTH_DECIBELS_MILLIWATT,
value=lambda status, _: status["wifi_sta"]["rssi"],
device_class=sensor.DEVICE_CLASS_SIGNAL_STRENGTH,
default_enabled=False,