This commit is contained in:
Kovid Goyal 2013-12-02 21:04:47 +05:30
parent e927c2310e
commit 5115b5d5f2

View File

@ -738,7 +738,7 @@ class Boss(QObject):
if editor is None: if editor is None:
if use_template is None: if use_template is None:
data = current_container().raw_data(name) data = current_container().raw_data(name)
if isbytestring(data): if isbytestring(data) and syntax in {'html', 'css', 'text', 'xml'}:
try: try:
data = data.decode('utf-8') data = data.decode('utf-8')
except UnicodeDecodeError: except UnicodeDecodeError: