Skip to content

Commit

Permalink
Prettier formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
malkstar committed Feb 16, 2024
1 parent 1baf2dc commit 8774f0c
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions src/components/ha-service-picker.ts
Original file line number Diff line number Diff line change
Expand Up @@ -114,14 +114,15 @@ class HaServicePicker extends LitElement {
if (!filter) {
return processedServices;
}
const split_filter = filter.split(' ')
return processedServices.filter(
(service) => {
const lower_service_name = service.name.toLowerCase();
const lower_service = service.service.toLowerCase();
return split_filter.every(f => lower_service_name.includes(f)) || split_filter.every(f => lower_service.toLowerCase().includes(f))
}
);
const split_filter = filter.split(" ");
return processedServices.filter((service) => {
const lower_service_name = service.name.toLowerCase();
const lower_service = service.service.toLowerCase();
return (
split_filter.every((f) => lower_service_name.includes(f)) ||
split_filter.every((f) => lower_service.toLowerCase().includes(f))
);
});
}
);

Expand Down

0 comments on commit 8774f0c

Please sign in to comment.