~ubuntu-branches/debian/sid/python-django/sid

« back to all changes in this revision

Viewing changes to django/templatetags/static.py

  • Committer: Package Import Robot
  • Author(s): Luke Faraone
  • Date: 2013-11-07 15:33:49 UTC
  • mfrom: (1.3.12)
  • Revision ID: package-import@ubuntu.com-20131107153349-e31sc149l2szs3jb
Tags: 1.6-1
* New upstream version. Closes: #557474, #724637.
* python-django now also suggests the installation of ipython,
  bpython, python-django-doc, and libgdal1.
  Closes: #636511, #686333, #704203
* Set package maintainer to Debian Python Modules Team.
* Bump standards version to 3.9.5, no changes needed.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
try:
2
 
    from urllib.parse import urljoin
3
 
except ImportError:     # Python 2
4
 
    from urlparse import urljoin
5
 
 
6
1
from django import template
7
2
from django.template.base import Node
8
3
from django.utils.encoding import iri_to_uri
 
4
from django.utils.six.moves.urllib.parse import urljoin
9
5
 
10
6
register = template.Library()
11
7
 
27
23
        """
28
24
        Class method to parse prefix node and return a Node.
29
25
        """
 
26
        # token.split_contents() isn't useful here because tags using this method don't accept variable as arguments
30
27
        tokens = token.contents.split()
31
28
        if len(tokens) > 1 and tokens[1] != 'as':
32
29
            raise template.TemplateSyntaxError(