mirror of
https://github.com/gorhill/uBlock.git
synced 2024-10-06 09:37:12 +02:00
Group lists with unknown group to special section
Related issue: https://old.reddit.com/r/uBlockOrigin/comments/1b6tad0
This commit is contained in:
parent
24d94e559d
commit
04fead8d8a
@ -229,6 +229,7 @@ const renderFilterLists = ( ) => {
|
|||||||
'social',
|
'social',
|
||||||
'annoyances',
|
'annoyances',
|
||||||
'regions',
|
'regions',
|
||||||
|
'unknown',
|
||||||
'custom'
|
'custom'
|
||||||
];
|
];
|
||||||
for ( const key of groupKeys ) {
|
for ( const key of groupKeys ) {
|
||||||
@ -238,9 +239,11 @@ const renderFilterLists = ( ) => {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
for ( const [ listkey, listDetails ] of Object.entries(response.available) ) {
|
for ( const [ listkey, listDetails ] of Object.entries(response.available) ) {
|
||||||
const groupkey = listDetails.group;
|
let groupkey = listDetails.group;
|
||||||
|
if ( listTree.hasOwnProperty(groupkey) === false ) {
|
||||||
|
groupkey = 'unknown';
|
||||||
|
}
|
||||||
const groupDetails = listTree[groupkey];
|
const groupDetails = listTree[groupkey];
|
||||||
if ( groupDetails === undefined ) { continue; }
|
|
||||||
if ( listDetails.parent !== undefined ) {
|
if ( listDetails.parent !== undefined ) {
|
||||||
let lists = groupDetails.lists;
|
let lists = groupDetails.lists;
|
||||||
for ( const parent of listDetails.parent.split('|') ) {
|
for ( const parent of listDetails.parent.split('|') ) {
|
||||||
|
Loading…
Reference in New Issue
Block a user