Skip to content

Commit 74e6c8f

Browse files
committed
Add missing test against null object
Related issue: uBlockOrigin/uBlock-issues#4047
1 parent bf7c30b commit 74e6c8f

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/js/jsonpath.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -350,7 +350,7 @@ export class JSONPath {
350350
return listout;
351351
}
352352
#expandKey(owner, k) {
353-
if ( typeof owner !== 'object' ) { return; }
353+
if ( typeof owner !== 'object' || owner === null ) { return; }
354354
if ( Array.isArray(k) ) {
355355
const out = [];
356356
for ( const a of k ) {

0 commit comments

Comments
 (0)