mirror of
https://github.com/home-assistant/core.git
synced 2025-07-22 04:37:06 +00:00
Fix Tuya Light without brightness (#26534)
Return none if there is brightness data from tuya https://github.com/home-assistant/home-assistant/issues/25896
This commit is contained in:
parent
7d71976e01
commit
702e63e6e8
@ -40,6 +40,8 @@ class TuyaLight(TuyaDevice, Light):
|
||||
@property
|
||||
def brightness(self):
|
||||
"""Return the brightness of the light."""
|
||||
if self.tuya.brightness() is None:
|
||||
return None
|
||||
return int(self.tuya.brightness())
|
||||
|
||||
@property
|
||||
|
Loading…
x
Reference in New Issue
Block a user