remove unnecessary variable & add FPL to device info name
This commit is contained in:
@@ -24,10 +24,9 @@ class FplEntity(CoordinatorEntity, SensorEntity):
|
|||||||
@property
|
@property
|
||||||
def unique_id(self):
|
def unique_id(self):
|
||||||
"""Return the ID of this device."""
|
"""Return the ID of this device."""
|
||||||
id = "{}{}{}".format(
|
return "{}{}{}".format(
|
||||||
DOMAIN, self.account, self.sensorName.lower().replace(" ", "")
|
DOMAIN, self.account, self.sensorName.lower().replace(" ", "")
|
||||||
)
|
)
|
||||||
return id
|
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def name(self):
|
def name(self):
|
||||||
@@ -37,7 +36,7 @@ class FplEntity(CoordinatorEntity, SensorEntity):
|
|||||||
def device_info(self):
|
def device_info(self):
|
||||||
return {
|
return {
|
||||||
"identifiers": {(DOMAIN, self.account)},
|
"identifiers": {(DOMAIN, self.account)},
|
||||||
"name": f"Account {self.account}",
|
"name": f"FPL Account {self.account}",
|
||||||
"model": VERSION,
|
"model": VERSION,
|
||||||
"manufacturer": "Florida Power & Light",
|
"manufacturer": "Florida Power & Light",
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user