Some rules have no parentStyleSheet.  Add a null check.
r=cbiesinger sr=bzbarsky
This commit is contained in:
caillon%returnzero.com 2002-11-13 21:48:46 +00:00
Родитель 7e404dbe23
Коммит e0839b608f
1 изменённых файлов: 11 добавлений и 5 удалений

Просмотреть файл

@ -364,14 +364,20 @@ function(aRow, aColId)
default:
return rule.cssText;
}
} else if (aColId == "olcFileURL") {
return rule.parentStyleSheet.href;
} else if (aColId == "olcWeight") {
}
if (aColId == "olcFileURL") {
return rule.parentStyleSheet ? rule.parentStyleSheet.href : "";
}
if (aColId == "olcWeight") {
return rule.type == CSSRule.STYLE_RULE ? this.mDOMUtils.getRuleWeight(rule) : "";
} else if (aColId == "olcLine") {
}
if (aColId == "olcLine") {
return rule.type == CSSRule.STYLE_RULE ? this.mDOMUtils.getRuleLine(rule) : "";
}
return "";
}