Pylint cleanups (#15626)

* Pylint 2 no-else-return fixes

* Remove unneeded abstract-class-not-used pylint disable
This commit is contained in:
Ville Skyttä authored and Paulus Schoutsen committed 2018-07-23 10:16:05 +02:00
1 parent a38c0d6d15
commit b7c336a687
166 files changed
+425 -490

No files matched your search

+2 -2
View File
@@ -64,7 +64,7 @@ class ZWaveMultilevelSensor(ZWaveSensor):
"""Return the state of the sensor."""
if self._units in ('C', 'F'):
return round(self._state, 1)
elif isinstance(self._state, float):
if isinstance(self._state, float):
return round(self._state, 2)
return self._state
@@ -74,7 +74,7 @@ class ZWaveMultilevelSensor(ZWaveSensor):
"""Return the unit the value is expressed in."""
if self._units == 'C':
return TEMP_CELSIUS
elif self._units == 'F':
if self._units == 'F':
return TEMP_FAHRENHEIT
return self._units