Fixed #10717 - Escape result of admin_media_prefix template tag.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@12140 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Jannis Leidel 2010-01-09 20:04:14 +00:00
parent bacfe3f3e8
commit 73d636f740
1 changed files with 2 additions and 1 deletions

View File

@ -1,4 +1,5 @@
from django.template import Library
from django.utils.encoding import iri_to_uri
register = Library()
@ -10,5 +11,5 @@ def admin_media_prefix():
from django.conf import settings
except ImportError:
return ''
return settings.ADMIN_MEDIA_PREFIX
return iri_to_uri(settings.ADMIN_MEDIA_PREFIX)
admin_media_prefix = register.simple_tag(admin_media_prefix)