1
0
mirror of https://github.com/django/django.git synced 2025-10-24 14:16:09 +00:00

Fixed #26705 -- Fixed plural versions of languages not supported by Django.

This commit is contained in:
Thejaswi Puthraya
2016-06-07 18:32:42 +05:30
committed by Tim Graham
parent c4980e28e5
commit c8d2120b06
2 changed files with 16 additions and 0 deletions

View File

@@ -113,6 +113,9 @@ class DjangoTranslation(gettext_module.GNUTranslations):
self.__to_language = to_language(language)
self.__locale = to_locale(language)
self._catalog = None
# If a language doesn't have a catalog, use the Germanic default for
# pluralization: anything except one is pluralized.
self.plural = lambda n: int(n != 1)
if self.domain == 'django':
if localedirs is not None: