mirror of
https://git.deluge-torrent.org/deluge
synced 2025-04-21 12:04:51 +00:00
fix rendering of templates when translations bring in utf-8 characters
This commit is contained in:
parent
030c5b51d4
commit
c57900d4f6
1 changed files with 1 additions and 3 deletions
|
@ -26,12 +26,10 @@ import gettext
|
|||
from mako.template import Template as MakoTemplate
|
||||
from deluge import common
|
||||
|
||||
_ = gettext.gettext
|
||||
|
||||
class Template(MakoTemplate):
|
||||
|
||||
builtins = {
|
||||
"_": _,
|
||||
"_": lambda x: gettext.gettext(x).decode("utf-8"),
|
||||
"version": common.get_version()
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue