File tree Expand file tree Collapse file tree 1 file changed +5
-7
lines changed
Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -648,19 +648,17 @@ def _create_legacy_gateway(self) -> None:
648648 if value is not None :
649649 self ._appl_data [self .gateway_id ].update ({key : value }) # type: ignore[misc]
650650
651- # For legacy P1 collect the connected SmartMeter info
652- if self .smile_type == "power" :
653- appl = Munch ()
654- self ._p1_smartmeter_info_finder (appl )
655-
656651 def _all_appliances (self ) -> None :
657652 """Collect all appliances with relevant info."""
658653 self ._all_locations ()
659654
660655 if self ._smile_legacy :
661656 self ._create_legacy_gateway ()
662- # Legacy P1 has no more devices
657+ # For legacy P1 collect the connected SmartMeter info
663658 if self .smile_type == "power" :
659+ appl = Munch ()
660+ self ._p1_smartmeter_info_finder (appl )
661+ # Legacy P1 has no more devices
664662 return
665663
666664 for appliance in self ._appliances .findall ("./appliance" ):
@@ -729,7 +727,7 @@ def _all_appliances(self) -> None:
729727 for item in self ._appl_data :
730728 if item != self .gateway_id :
731729 self .gateway_id = item
732- # Leave for-loop to avoid a 2nd switch
730+ # Leave for-loop to avoid a 2nd device_id switch
733731 break
734732
735733 def _match_locations (self ) -> dict [str , ThermoLoc ]:
You can’t perform that action at this time.
0 commit comments