forked from pool/python-Babel
update to version 2.2.0 OBS-URL: https://build.opensuse.org/request/show/357119 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-Babel?expand=0&rev=24
14 lines
550 B
Diff
14 lines
550 B
Diff
--- babel/dates.py.old 2015-01-28 16:54:06.306129842 -0800
|
|
+++ babel/dates.py 2015-01-28 16:54:44.574118917 -0800
|
|
@@ -308,7 +308,9 @@
|
|
datetime = datetime.replace(tzinfo=UTC)
|
|
locale = Locale.parse(locale)
|
|
|
|
- offset = datetime.tzinfo.utcoffset(datetime)
|
|
+ # fix for mitsuhiko/babel#133 : Any time will do since we just want the
|
|
+ # offset
|
|
+ offset = datetime.tzinfo.utcoffset(datetime_.utcnow())
|
|
seconds = offset.days * 24 * 60 * 60 + offset.seconds
|
|
hours, seconds = divmod(seconds, 3600)
|
|
if width == 'short':
|