Bug 1331599 - script-generated patch to replace removeEventListener calls with the once option when possible, r=jaws.
This commit is contained in:
@@ -213,10 +213,9 @@ function onFocus(window) {
|
||||
resolve(window);
|
||||
}
|
||||
else {
|
||||
window.addEventListener("focus", function focusListener() {
|
||||
window.removeEventListener("focus", focusListener, true);
|
||||
window.addEventListener("focus", function() {
|
||||
resolve(window);
|
||||
}, true);
|
||||
}, {capture: true, once: true});
|
||||
}
|
||||
|
||||
return promise;
|
||||
|
||||
Reference in New Issue
Block a user