minor change so we don't have two variables named "attrName" and "attrname", and make it more explicit that these are style-related attributes.

git-svn-id: http://svg-edit.googlecode.com/svn/trunk@2380 eee81c28-f429-11dd-99c0-75d572ba1ddd
master
Waldir Pimenta 2013-02-13 17:21:13 +00:00
parent 5dcdc76912
commit 7f560c0ed1
1 changed files with 4 additions and 4 deletions

View File

@ -206,11 +206,11 @@ svgedit.sanitize.sanitizeSvg = function(node) {
p = props.length;
while(p--) {
var nv = props[p].split(":");
var attrname = $.trim(nv[0]);
var attrval = $.trim(nv[1]);
var styleAttrName = $.trim(nv[0]);
var styleAttrVal = $.trim(nv[1]);
// Now check that this attribute is supported
if (allowedAttrs.indexOf(attrname) >= 0) {
node.setAttribute(attrname, attrval);
if (allowedAttrs.indexOf(styleAttrName) >= 0) {
node.setAttribute(styleAttrName, styleAttrVal);
}
}
node.removeAttribute('style');