Utilize escapeHtml

This commit is contained in:
Chocobo1 2017-02-11 15:06:15 +08:00 committed by sledgehammer999
parent 6ca3e4f094
commit 0fb3b18a8f
No known key found for this signature in database
GPG key ID: 6E4A2D025B7CC9A2
4 changed files with 9 additions and 5 deletions

View file

@ -130,7 +130,7 @@ var loadTorrentData = function() {
temp = "QBT_TR(Unknown)QBT_TR";
$('pieces').set('html', temp);
$('created_by').set('html', data.created_by);
$('created_by').set('html', escapeHtml(data.created_by));
if (data.addition_date != -1)
temp = new Date(data.addition_date * 1000).toLocaleString();
else
@ -152,7 +152,7 @@ var loadTorrentData = function() {
$('save_path').set('html', data.save_path);
$('comment').set('html', parseHtmlLinks(data.comment));
$('comment').set('html', parseHtmlLinks(escapeHtml(data.comment)));
}
else {
clearData();