mercurial/templatefilters.py
changeset 43086 bbcbb82e3589
parent 43077 687b865b95ad
child 43094 e8cf9ad52a78
--- a/mercurial/templatefilters.py	Sun Oct 06 13:28:56 2019 -0400
+++ b/mercurial/templatefilters.py	Sun Oct 06 14:51:45 2019 -0400
@@ -367,7 +367,7 @@
     """Any text. Returns the input text rendered as a sequence of
     XML entities.
     """
-    text = unicode(text, pycompat.sysstr(encoding.encoding), r'replace')
+    text = pycompat.unicode(text, pycompat.sysstr(encoding.encoding), r'replace')
     return b''.join([b'&#%d;' % ord(c) for c in text])