File tree Expand file tree Collapse file tree 2 files changed +2
-0
lines changed
platform/mv3/extension/js/scripting Expand file tree Collapse file tree 2 files changed +2
-0
lines changed Original file line number Diff line number Diff line change @@ -119,6 +119,7 @@ class PSelectorMatchesAttrTask extends PSelectorTask {
119
119
this . reValue = regexFromString ( task [ 1 ] . value , true ) ;
120
120
}
121
121
transpose ( node , output ) {
122
+ if ( typeof node . getAttributeNames !== 'function' ) { return ; }
122
123
const attrs = node . getAttributeNames ( ) ;
123
124
for ( const attr of attrs ) {
124
125
if ( this . reAttr . test ( attr ) === false ) { continue ; }
Original file line number Diff line number Diff line change @@ -99,6 +99,7 @@ class PSelectorMatchesAttrTask extends PSelectorTask {
99
99
this . reValue = regexFromString ( task [ 1 ] . value , true ) ;
100
100
}
101
101
transpose ( node , output ) {
102
+ if ( typeof node . getAttributeNames !== 'function' ) { return ; }
102
103
const attrs = node . getAttributeNames ( ) ;
103
104
for ( const attr of attrs ) {
104
105
if ( this . reAttr . test ( attr ) === false ) { continue ; }
You can’t perform that action at this time.
0 commit comments