Fix recording timezone issue.

This commit is contained in:
Dermot Duffy
2024-08-26 13:10:19 -07:00
parent 2412cc5ac8
commit 09a15ab785
2 changed files with 14 additions and 4 deletions
+8 -2
View File
@@ -36,7 +36,10 @@ export const getRecordingsSummary = async (
type: 'frigate/recordings/summary',
instance_id: clientID,
camera: camera_name,
timezone: Intl.DateTimeFormat().resolvedOptions().timeZone,
// Ask for the summary relative to HA timezone
// See: https://github.com/dermotduffy/frigate-hass-card/issues/1267
timezone: hass.config.time_zone,
},
true,
// See: https://github.com/colinhacks/zod/pull/1752
@@ -148,7 +151,10 @@ export const getEventSummary = async (
{
type: 'frigate/events/summary',
instance_id: clientID,
timezone: Intl.DateTimeFormat().resolvedOptions().timeZone,
// Ask for the summary relative to HA timezone
// See: https://github.com/dermotduffy/frigate-hass-card/issues/1267
timezone: hass.config.time_zone,
},
true,
);