1
0
mirror of https://github.com/gorhill/uBlock.git synced 2024-09-04 18:19:38 +02:00

Ensure astSelectorsFromSelectorList receive expected arguments

Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/2554
This commit is contained in:
Raymond Hill 2023-03-23 14:57:31 -04:00
parent 6f0ab28258
commit 56b8201196
No known key found for this signature in database
GPG Key ID: 25E1490B761470C2

View File

@ -3348,6 +3348,7 @@ class ExtSelectorCompiler {
}
astSelectorsFromSelectorList(args) {
if ( Array.isArray(args) === false ) { return; }
if ( args.length < 3 ) { return; }
if ( args[0].data instanceof Object === false ) { return; }
if ( args[0].data.type !== 'SelectorList' ) { return; }