Upgrade pylint to 2.2.2 (#18750)

* Upgrade to 2.2.0

* simplifiable-if-expression fixes

* duplicate-string-formatting-argument fixes

* unused-import fixes

* Upgrade to 2.2.1

* Remove no longer needed disable

* Upgrade to 2.2.2
This commit is contained in:
Ville Skyttä authored and Paulus Schoutsen committed 2018-12-06 11:54:44 +01:00
1 parent 04c7d5c128
commit 1be440a72b
19 files changed
+35 -40

No files matched your search

+2 -2
View File
@@ -123,7 +123,7 @@ class I2CHatSwitch(ToggleEntity):
def turn_on(self, **kwargs):
"""Turn the device on."""
try:
state = True if self._invert_logic is False else False
state = self._invert_logic is False
self.I2C_HATS_MANAGER.write_dq(self._address, self._channel, state)
self.schedule_update_ha_state()
except I2CHatsException as ex:
@@ -132,7 +132,7 @@ class I2CHatSwitch(ToggleEntity):
def turn_off(self, **kwargs):
"""Turn the device off."""
try:
state = False if self._invert_logic is False else True
state = self._invert_logic is not False
self.I2C_HATS_MANAGER.write_dq(self._address, self._channel, state)
self.schedule_update_ha_state()
except I2CHatsException as ex: