Files @ 66dbfac066b0
Branch filter:

Location: website/www/conservancy/apps/news/templatetags/min.py

brett
Migrate RequestContext users to render() calls.

This was necessary because render_to_response no longer takes a
context_instance. We were always using this to pass in a RequestContext,
which the render shortcut can already do, so switch to that.
1
2
3
4
5
6
7
8
from django import template
register = template.Library()

@register.filter
def min(value, arg):
    if value > arg:
        return arg
    return value