Ticket #10604: ticket-10604-1.diff

File ticket-10604-1.diff, 683 bytes (added by bartTC, 6 years ago)
  • django/templatetags/i18n.py

    diff --git a/django/templatetags/i18n.py b/django/templatetags/i18n.py
    index 190cb70..fa61850 100644
    a b class BlockTranslateNode(Node): 
    7676        if self.plural and self.countervar and self.counter:
    7777            count = self.counter.resolve(context)
    7878            context[self.countervar] = count
    79             plural, vars = self.render_token_list(self.plural)
     79            plural, plural_vars = self.render_token_list(self.plural)
     80            vars += plural_vars
    8081            result = translation.ungettext(singular, plural, count)
    8182        else:
    8283            result = translation.ugettext(singular)
Back to Top