@library.global_function
def is_contributor(user):
    """Return whether the user is in the 'Registered as contributor' group."""
    return (user.is_authenticated() and
            user.groups.filter(name='Registered as contributor').count() > 0)
dataset/ETHPy150Open mozilla/kitsune/kitsune/users/templatetags/jinja_helpers.py/is_contributor/original