Commit 7b6d897a authored by Michal Čihař's avatar Michal Čihař

Give sane defaults to generated languages (issue #27)

parent 0e9e187b
......@@ -76,7 +76,12 @@ class TranslationManager(models.Manager):
try:
lang = Language.objects.get(code = code)
except Language.DoesNotExist:
lang = Language.objects.create(code = code, name = '%s (generated)' % code)
lang = Language.objects.create(
code = code,
name = '%s (generated)' % code,
nplurals = 2,
pluralequation = '(n != 1)',
)
translation, created = self.get_or_create(
language = lang,
subproject = subproject,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment