Ticket #4796: 4796-fix.diff

File 4796-fix.diff, 1.1 KB (added by durdinator, 17 years ago)

Patch, with regression test (fix typo)

  • django/utils/translation/__init__.py

     
    3939            g['real_%s' % name] = getattr(trans, name)
    4040
    4141    # Make the originally requested function call on the way out the door.
    42     return g[caller](*args, **kwargs)
     42    return g['real_%s' % caller](*args, **kwargs)
    4343
    4444g = globals()
    4545for name in __all__:
  • tests/regressiontests/i18n/tests.py

     
    3030>>> s4 = ugettext_lazy('Some other string')
    3131>>> s == s4
    3232False
     33
     34unicode(string_concat(...)) should not raise a TypeError - #4796
     35
     36>>> import django.utils.translation
     37>>> reload(django.utils.translation)
     38<module 'django.utils.translation' from ...>
     39>>> unicode(django.utils.translation.string_concat("dja", "ngo"))
     40u'django'
    3341"""
Back to Top