@register.function
@jinja2.contextfunction
def remora_url(context, url, lang=None, app=None, prefix=''):
    """Wrapper for urlresolvers.remora_url"""
    if lang is None:
        _lang = context['LANG']
        if _lang:
            lang = to_locale(_lang).replace('_', '-')
    if app is None:
        try:
            app = context['APP'].short
        except (AttributeError, __HOLE__):
            pass
    return urlresolvers.remora_url(url=url, lang=lang, app=app, prefix=prefix)
dataset/ETHPy150Open mozilla/addons-server/src/olympia/amo/helpers.py/remora_url