diff --git a/django/utils/html.py b/django/utils/html.py index 311a4d5c35..79b0d6d5af 100644 --- a/django/utils/html.py +++ b/django/utils/html.py @@ -25,8 +25,6 @@ del x # Temporary variable def escape(html): "Returns the given HTML with ampersands, quotes and carets encoded" - if not isinstance(html, basestring): - html = force_unicode(html) return force_unicode(html).replace('&', '&').replace('<', '<').replace('>', '>').replace('"', '"').replace("'", ''') escape = allow_lazy(escape, unicode)