Fix broken default time zone
This commit is contained in:
parent
8493256e3e
commit
c648251380
@ -246,7 +246,7 @@ class System(namedtuple("System", ["id", "hid", "name", "description", "tag", "a
|
|||||||
:returns: The `pytz.tzinfo` instance of the newly set time zone.
|
:returns: The `pytz.tzinfo` instance of the newly set time zone.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
canonical_name = canonicalize_tz_name(tz_name)
|
canonical_name = canonicalize_tz_name(tz_name or "UTC")
|
||||||
if not canonical_name:
|
if not canonical_name:
|
||||||
raise errors.InvalidTimeZoneError(tz_name)
|
raise errors.InvalidTimeZoneError(tz_name)
|
||||||
tz = pytz.timezone(canonical_name)
|
tz = pytz.timezone(canonical_name)
|
||||||
|
Loading…
Reference in New Issue
Block a user