Fix category-picker unknown check (#28957)

This commit is contained in:
Wendelin 2026-01-13 10:39:05 +01:00 committed by GitHub
parent 9ce9d254f8
commit 66e6cb8dbc
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -101,7 +101,13 @@ export class HaCategoryPicker extends SubscribeMixin(LitElement) {
);
private _getCategories = memoizeOne(
(categories: CategoryRegistryEntry[] | undefined): PickerComboBoxItem[] => {
(
categories: CategoryRegistryEntry[] | undefined
): PickerComboBoxItem[] | undefined => {
if (!categories) {
return undefined;
}
if (!categories || categories.length === 0) {
return [
{