From f17e9178a91a7df96fd252f66e058e880eac8932 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Aleksander=20=C5=81ukasz?= Date: Tue, 16 Jul 2013 11:51:42 +0200 Subject: [PATCH 1/1] Fix: escaping html in familyTree properly --- modules/nodeFamilyTree/nodeFamilyTree.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/nodeFamilyTree/nodeFamilyTree.js b/modules/nodeFamilyTree/nodeFamilyTree.js index af5d4d7..0825506 100644 --- a/modules/nodeFamilyTree/nodeFamilyTree.js +++ b/modules/nodeFamilyTree/nodeFamilyTree.js @@ -49,14 +49,14 @@ return function(sandbox) { if(child.getText) { var text = child.getText(); if(!text) - text = '<pusty tekst>'; + text = ''; else { if(text.length > 13) { text = text.substr(0,13) + '...'; } text = '"' + text + '"'; } - children.push({repr: text, bold: child.sameNode(textElement)}); + children.push({repr: _.escape(text), bold: child.sameNode(textElement)}); } else { children.push({repr: child.getWlxmlTag() + (child.getWlxmlClass() ? ' / ' + child.getWlxmlClass() : '')}); } -- 2.20.1