Fix hue ct (#33791)

This commit is contained in:
Paulus Schoutsen
2020-04-08 02:31:41 -07:00
committed by GitHub
parent ad619817c6
commit ba8ae17487
2 changed files with 3 additions and 4 deletions

View File

@@ -280,7 +280,7 @@ class HueLight(Light):
@property
def min_mireds(self):
"""Return the coldest color_temp that this light supports."""
if self.is_group:
if self.is_group or "ct" not in self.light.controlcapabilities:
return super().min_mireds
return self.light.controlcapabilities["ct"]["min"]
@@ -288,8 +288,8 @@ class HueLight(Light):
@property
def max_mireds(self):
"""Return the warmest color_temp that this light supports."""
if self.is_group:
return super().min_mireds
if self.is_group or "ct" not in self.light.controlcapabilities:
return super().max_mireds
return self.light.controlcapabilities["ct"]["max"]

View File

@@ -109,7 +109,6 @@ LIGHT_2_CAPABILITIES = {
"maxlumen": 600,
"colorgamuttype": "A",
"colorgamut": [[0.704, 0.296], [0.2151, 0.7106], [0.138, 0.08]],
"ct": {"min": 153, "max": 500},
},
"streaming": {"renderer": True, "proxy": False},
}