Skip to content

Commit

Permalink
Merge pull request #517 from justinlampley/FixWifiDeviceSelectionList…
Browse files Browse the repository at this point in the history
…Filter

When filtering the Wifi device selection list, examine the lua name as well as the prior target name.
  • Loading branch information
jurgelenas authored Jun 13, 2023
2 parents bdf993d + 28768bc commit 9e7b712
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions src/ui/views/ConfiguratorView/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -893,9 +893,17 @@ const ConfiguratorView: FunctionComponent<ConfiguratorViewProps> = (props) => {
wifiDevice={wifiDevice}
wifiDevices={Array.from(networkDevices.values()).filter(
(item) => {
return deviceTarget?.name
?.toUpperCase()
.startsWith(item.target.toUpperCase());
return (
deviceTarget?.name
?.toUpperCase()
.startsWith(item.target.toUpperCase()) ||
device?.luaName?.toUpperCase() ===
item.deviceName.toUpperCase() ||
(device?.priorTargetName &&
item.target
.toUpperCase()
.startsWith(device.priorTargetName.toUpperCase()))
);
}
)}
onChange={onWifiDevice}
Expand Down

0 comments on commit 9e7b712

Please sign in to comment.