3.4 lint clean up

pull/12534/head
Tom Harris 2018-02-19 21:35:23 -05:00
parent 4a2d320823
commit 0d8fb992b1
2 changed files with 3 additions and 3 deletions

View File

@ -121,6 +121,7 @@ State = collections.namedtuple('Product', 'stateType platform')
class IPDB(object): class IPDB(object):
"""Embodies the INSTEON Product Database static data and access methods.""" """Embodies the INSTEON Product Database static data and access methods."""
def __init__(self): def __init__(self):
"""Create the INSTEON Product Database (IPDB).""" """Create the INSTEON Product Database (IPDB)."""
from insteonplm.states.onOff import (OnOffSwitch, from insteonplm.states.onOff import (OnOffSwitch,
@ -159,8 +160,7 @@ class IPDB(object):
yield product yield product
def __getitem__(self, key): def __getitem__(self, key):
"""Return a Home Assistant platform from an INSTEON state type. """Return a Home Assistant platform from an INSTEON state type."""
"""
for state in self.states: for state in self.states:
if isinstance(key, state.stateType): if isinstance(key, state.stateType):
return state return state

View File

@ -125,7 +125,7 @@ class InsteonPLMOpenClosedDevice(SwitchDevice):
@property @property
def name(self): def name(self):
"""Return the name of the node. (used for Entity_ID)""" """Return the name of the node (used for Entity_ID)."""
name = '' name = ''
if self._insteon_device_state.group == 0x01: if self._insteon_device_state.group == 0x01:
name = self._insteon_device.id name = self._insteon_device.id