forked from home-assistant/core
Fix incorrect unit (#53274)
This commit is contained in:
@@ -12,6 +12,7 @@ from homeassistant.components.sensor import STATE_CLASS_MEASUREMENT, SensorEntit
|
|||||||
from homeassistant.config_entries import ConfigEntry
|
from homeassistant.config_entries import ConfigEntry
|
||||||
from homeassistant.const import (
|
from homeassistant.const import (
|
||||||
DATA_GIGABYTES,
|
DATA_GIGABYTES,
|
||||||
|
DATA_RATE_KILOBITS_PER_SECOND,
|
||||||
DATA_RATE_KILOBYTES_PER_SECOND,
|
DATA_RATE_KILOBYTES_PER_SECOND,
|
||||||
DEVICE_CLASS_TIMESTAMP,
|
DEVICE_CLASS_TIMESTAMP,
|
||||||
)
|
)
|
||||||
@@ -113,14 +114,14 @@ SENSOR_DATA = {
|
|||||||
state_provider=_retrieve_kb_s_received_state,
|
state_provider=_retrieve_kb_s_received_state,
|
||||||
),
|
),
|
||||||
"max_kb_s_sent": SensorData(
|
"max_kb_s_sent": SensorData(
|
||||||
name="Max kB/s sent",
|
name="Max kbit/s sent",
|
||||||
unit_of_measurement=DATA_RATE_KILOBYTES_PER_SECOND,
|
unit_of_measurement=DATA_RATE_KILOBITS_PER_SECOND,
|
||||||
icon="mdi:upload",
|
icon="mdi:upload",
|
||||||
state_provider=_retrieve_max_kb_s_sent_state,
|
state_provider=_retrieve_max_kb_s_sent_state,
|
||||||
),
|
),
|
||||||
"max_kb_s_received": SensorData(
|
"max_kb_s_received": SensorData(
|
||||||
name="Max kB/s received",
|
name="Max kbit/s received",
|
||||||
unit_of_measurement=DATA_RATE_KILOBYTES_PER_SECOND,
|
unit_of_measurement=DATA_RATE_KILOBITS_PER_SECOND,
|
||||||
icon="mdi:download",
|
icon="mdi:download",
|
||||||
state_provider=_retrieve_max_kb_s_received_state,
|
state_provider=_retrieve_max_kb_s_received_state,
|
||||||
),
|
),
|
||||||
|
Reference in New Issue
Block a user