def patch_resolve():
    global django_resolve
    if urlresolvers.resolve is not resolve:
        django_resolve = urlresolvers.resolve
        urlresolvers.resolve = resolve
Monkey-patches the urlresolvers.resolve function. Will not patch twice.
dataset/ETHPy150Open carljm/django-localeurl/localeurl/models.py/patch_resolve