mirror of
https://github.com/django/django.git
synced 2025-07-04 17:59:13 +00:00
Worked around the situation when getdefaultlocale() might return (None, None),
which apparently can happen. git-svn-id: http://code.djangoproject.com/svn/django/branches/unicode@5546 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
dbb785c0b4
commit
b89d409bf7
@ -5,7 +5,7 @@ import time
|
|||||||
from datetime import timedelta, tzinfo
|
from datetime import timedelta, tzinfo
|
||||||
from django.utils.encoding import smart_unicode
|
from django.utils.encoding import smart_unicode
|
||||||
|
|
||||||
DEFAULT_ENCODING = locale.getdefaultlocale()[1]
|
DEFAULT_ENCODING = locale.getdefaultlocale()[1] or 'ascii'
|
||||||
|
|
||||||
class FixedOffset(tzinfo):
|
class FixedOffset(tzinfo):
|
||||||
"Fixed offset in minutes east from UTC."
|
"Fixed offset in minutes east from UTC."
|
||||||
|
Loading…
x
Reference in New Issue
Block a user