Skip to content

Commit

Permalink
Remove constructor extension
Browse files Browse the repository at this point in the history
Co-authored-by: Teemu R. <tpr@iki.fi>
  • Loading branch information
Kirmas and rytilahti authored Dec 14, 2021
1 parent 3a77959 commit 8977a18
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions miio/integrations/yeelight/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -265,15 +265,14 @@ def __init__(
debug: int = 0,
lazy_discover: bool = True,
model: str = None,
light_type: YeelightSubLightType = YeelightSubLightType.Main, # for now only Main support this is for future PR.
) -> None:
super().__init__(ip, token, start_id, debug, lazy_discover, model=model)
if Yeelight._spec_helper is None:
Yeelight._spec_helper = YeelightSpecHelper()
Yeelight._supported_models = Yeelight._spec_helper.supported_models

self._model_info = Yeelight._spec_helper.get_model_info(self.model)
self._light_type = light_type
self._light_type = YeelightSubLightType.Main
self._light_info = self._model_info.lamps[self._light_type]
self._color_temp_range = self._light_info.color_temp

Expand Down

0 comments on commit 8977a18

Please sign in to comment.