mirror of https://github.com/gorhill/uBlock.git
Fix DOM watcher not reporting removal of elements
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1392
Regression from:
- 6112a68faf
This commit is contained in:
parent
2f841259ae
commit
cb71fb494c
|
@ -362,7 +362,7 @@ vAPI.SafeAnimationFrame = class {
|
|||
};
|
||||
|
||||
// https://github.com/chrisaljoudi/uBlock/issues/205
|
||||
// Do not handle added node directly from within mutation observer.
|
||||
// Do not handle added node directly from within mutation observer.
|
||||
const observerHandler = function(mutations) {
|
||||
let i = mutations.length;
|
||||
while ( i-- ) {
|
||||
|
@ -376,7 +376,7 @@ vAPI.SafeAnimationFrame = class {
|
|||
removedNodeLists.push(nodeList);
|
||||
}
|
||||
}
|
||||
if ( addedNodeLists.length !== 0 || removedNodes ) {
|
||||
if ( addedNodeLists.length !== 0 || removedNodeLists.length !== 0 ) {
|
||||
safeObserverHandlerTimer.start(
|
||||
addedNodeLists.length < 100 ? 1 : undefined
|
||||
);
|
||||
|
|
Loading…
Reference in New Issue