mirror of
https://github.com/django/django.git
synced 2025-10-31 09:41:08 +00:00
Removed fix_ampersands template filter per deprecation timeline.
Also removed related utility functions: * django.utils.html.fix_ampersands * django.utils.html.clean_html
This commit is contained in:
@@ -12,7 +12,7 @@ from django.conf import settings
|
||||
from django.utils import formats
|
||||
from django.utils.dateformat import format, time_format
|
||||
from django.utils.encoding import force_text, iri_to_uri
|
||||
from django.utils.html import (conditional_escape, escapejs, fix_ampersands,
|
||||
from django.utils.html import (conditional_escape, escapejs,
|
||||
escape, urlize as _urlize, linebreaks, strip_tags, avoid_wrapping,
|
||||
remove_tags)
|
||||
from django.utils.http import urlquote
|
||||
@@ -82,12 +82,6 @@ def escapejs_filter(value):
|
||||
return escapejs(value)
|
||||
|
||||
|
||||
@register.filter("fix_ampersands", is_safe=True)
|
||||
@stringfilter
|
||||
def fix_ampersands_filter(value):
|
||||
"""Replaces ampersands with ``&`` entities."""
|
||||
return fix_ampersands(value)
|
||||
|
||||
# Values for testing floatformat input against infinity and NaN representations,
|
||||
# which differ across platforms and Python versions. Some (i.e. old Windows
|
||||
# ones) are not recognized by Decimal but we want to return them unchanged vs.
|
||||
|
||||
Reference in New Issue
Block a user