1
0
mirror of synced 2024-11-26 14:56:07 +03:00

fix markup escaping. fixes #268

This commit is contained in:
Igor Vaynberg 2012-07-26 08:47:10 +03:00
parent bb51eb7120
commit 00058ab315

View File

@ -92,7 +92,13 @@
nextUid=(function() { var counter=1; return function() { return counter++; }; }()); nextUid=(function() { var counter=1; return function() { return counter++; }; }());
function escapeMarkup(markup) { return markup.replace("&", "&"); } function escapeMarkup(markup) {
if (typeof(markup) === "string") {
return markup.replace("&", "&");
} else {
return markup;
}
}
function indexOf(value, array) { function indexOf(value, array) {
var i = 0, l = array.length, v; var i = 0, l = array.length, v;