代码风格

This commit is contained in:
Lei Zongmin
2013-05-08 16:23:16 +08:00
parent a5e2946f8f
commit 021c664f14

View File

@@ -174,7 +174,7 @@ FilterXSS.prototype.filterAttributes = function (tagName, attrs) {
}
value = _value.trim();
var newValue = me.onTagAttr(tagName, name, value);
if (typeof(newValue) !== 'undefined') {
if (typeof newValue !== 'undefined') {
value = newValue;
}
}
@@ -265,7 +265,7 @@ FilterXSS.prototype.addNewTag = function (tag, currentPos, targetPos) {
originalPosition: currentPos - tag.length + 1
};
var tagHtml = this.onIgnoreTag(tagName, tag, options);
if (typeof(tagHtml) === 'undefined') {
if (typeof tagHtml === 'undefined') {
tagHtml = noTag(tag);
}
rethtml += tagHtml;