1
0
mirror of https://github.com/beestat/app.git synced 2025-07-31 14:33:51 -04:00

Fixed #216 - Time is sometimes off by an hour

Long story...
This commit is contained in:
Jon Ziebell 2020-01-22 20:40:09 -05:00
parent 8d6ed9dba5
commit 225a517907

View File

@ -868,7 +868,7 @@ class ecobee_thermostat extends cora\crud {
private function get_time_zone($thermostat, $ecobee_thermostat) {
$time_zone = $ecobee_thermostat['location']['timeZone'];
if (in_array($time_zone, timezone_identifiers_list()) === true) {
if (in_array($time_zone, timezone_identifiers_list(DateTimeZone::ALL_WITH_BC)) === true) {
return $time_zone;
} else if ($ecobee_thermostat['location']['timeZoneOffsetMinutes'] !== '') {
$offset_seconds = $ecobee_thermostat['location']['timeZoneOffsetMinutes'] * 60;