Skip to content

Commit

Permalink
Revert some VS Code line breakage.
Browse files Browse the repository at this point in the history
  • Loading branch information
crkochan committed Sep 6, 2021
1 parent 50d6865 commit 73e3314
Showing 1 changed file with 4 additions and 12 deletions.
16 changes: 4 additions & 12 deletions custom_components/sunpower/binary_sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,17 +41,13 @@ async def async_setup_entry(hass, config_entry, async_add_entities):
_LOGGER.error("Cannot find any power meters")
else:
for data in sunpower_data[METER_DEVICE_TYPE].values():
entities.append(
SunPowerMeterState(coordinator, data, pvs, do_descriptive_names)
)
entities.append(SunPowerMeterState(coordinator, data, pvs, do_descriptive_names))

if INVERTER_DEVICE_TYPE not in sunpower_data:
_LOGGER.error("Cannot find any power inverters")
else:
for data in sunpower_data[INVERTER_DEVICE_TYPE].values():
entities.append(
SunPowerInverterState(coordinator, data, pvs, do_descriptive_names)
)
entities.append(SunPowerInverterState(coordinator, data, pvs, do_descriptive_names))

async_add_entities(entities, True)

Expand Down Expand Up @@ -120,9 +116,7 @@ def unique_id(self):
@property
def state(self):
"""Get the current value"""
return self.coordinator.data[METER_DEVICE_TYPE][self.base_unique_id][
METER_STATE
]
return self.coordinator.data[METER_DEVICE_TYPE][self.base_unique_id][METER_STATE]

@property
def is_on(self):
Expand Down Expand Up @@ -158,9 +152,7 @@ def unique_id(self):
@property
def state(self):
"""Get the current value"""
return self.coordinator.data[INVERTER_DEVICE_TYPE][self.base_unique_id][
INVERTER_STATE
]
return self.coordinator.data[INVERTER_DEVICE_TYPE][self.base_unique_id][INVERTER_STATE]

@property
def is_on(self):
Expand Down

0 comments on commit 73e3314

Please sign in to comment.