aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/document-matchers.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/document-matchers.js b/lib/document-matchers.js
index bee2ac9..9b01dfd 100644
--- a/lib/document-matchers.js
+++ b/lib/document-matchers.js
@@ -24,7 +24,7 @@ function Matcher(elementType, options) {
Matcher.prototype.matches = function(element) {
return element.type === this._elementType &&
(this._styleId === undefined || element.styleId === this._styleId) &&
- (this._styleName === undefined || element.styleName === this._styleName) &&
+ (this._styleName === undefined || (element.styleName && element.styleName.toUpperCase() === this._styleName.toUpperCase())) &&
(this._listIndex === undefined || isList(element, this._listIndex, this._listIsOrdered));
};