fix:修复阿里云主机同步时UTC解析错误

pull/330/head
lucius 2021-06-11 15:48:08 +08:00
parent 5f6a93cac3
commit 62e14c86d9
1 changed files with 1 additions and 1 deletions

View File

@ -48,7 +48,7 @@ def parse_utc_date(value):
return None
s_format = '%Y-%m-%dT%H:%M:%S%z'
if len(value) == 17:
s_format = '%Y-%m-%dT%H:%M%z'
s_format = '%Y-%m-%dT%H:%MZ'
date = datetime.strptime(value, s_format)
return date.astimezone().strftime('%Y-%m-%d %H:%M:%S')