1
0
mirror of https://github.com/home-assistant/frontend.git synced 2025-12-20 02:38:53 +00:00

Fix logbook keeps loading (#24351)

* Logbook loading

* Redo typing

* small fixes

* async/sync fixes
This commit is contained in:
Simon Lamon
2025-03-13 17:18:24 +01:00
committed by GitHub
parent 28c355812c
commit d42bd36a3e
2 changed files with 33 additions and 49 deletions

View File

@@ -1,4 +1,4 @@
import type { HassEntity } from "home-assistant-js-websocket";
import type { HassEntity, UnsubscribeFunc } from "home-assistant-js-websocket";
import {
BINARY_STATE_OFF,
BINARY_STATE_ON,
@@ -119,7 +119,7 @@ export const subscribeLogbook = (
endDate: string,
entityIds?: string[],
deviceIds?: string[]
): Promise<() => Promise<void>> => {
): Promise<UnsubscribeFunc> => {
// If all specified filters are empty lists, we can return an empty list.
if (
(entityIds || deviceIds) &&