Address late review of Flipr (#54668)

* Code format correction

* Other code review remarks of MartinHjelmare

* Simplification of flipr instantiation

* Formatting correction
This commit is contained in:
cnico 2021-08-16 07:12:39 +02:00 committed by GitHub
parent 094f7d38ad
commit 416668c289
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 7 additions and 9 deletions

View file

@ -6,6 +6,7 @@ from homeassistant.const import (
ATTR_ATTRIBUTION,
DEVICE_CLASS_TEMPERATURE,
DEVICE_CLASS_TIMESTAMP,
ELECTRIC_POTENTIAL_MILLIVOLT,
TEMP_CELSIUS,
)
@ -14,7 +15,7 @@ from .const import ATTRIBUTION, CONF_FLIPR_ID, DOMAIN
SENSORS = {
"chlorine": {
"unit": "mV",
"unit": ELECTRIC_POTENTIAL_MILLIVOLT,
"icon": "mdi:pool",
"name": "Chlorine",
"device_class": None,
@ -33,7 +34,7 @@ SENSORS = {
"device_class": DEVICE_CLASS_TIMESTAMP,
},
"red_ox": {
"unit": "mV",
"unit": ELECTRIC_POTENTIAL_MILLIVOLT,
"icon": "mdi:pool",
"name": "Red OX",
"device_class": None,