File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -510,14 +510,17 @@ async def update_node_details(
510510 hardware , model_info = version_to_model (hardware )
511511 model_info = model_info .split (" " )
512512 self ._node_info .model = model_info [0 ]
513+ # Correct model when node_type doesn't match
514+ # Switch reports hardware version of paired Circle (pw_usb_beta #245)
513515 if (
514516 self ._node_info .node_type is not None
515517 and (
516- correct_model := str ( self ._node_info .node_type .name ) .lower ().split ("_" )[0 ]
518+ correct_model := self ._node_info .node_type .name .lower ().split ("_" )[0 ]
517519 ) not in self ._node_info .model .lower ()
518520 ):
519521 self ._node_info .model = correct_model .capitalize ()
520- model_info [0 ] = self ._node_info .model
522+ # Replace model_info list
523+ model_info = [self ._node_info .model ]
521524
522525 # Handle + devices
523526 if len (model_info ) > 1 and "+" in model_info [1 ]:
You can’t perform that action at this time.
0 commit comments