1
0
mirror of https://github.com/gorhill/uBlock.git synced 2024-07-08 04:49:12 +02:00

code review: this is needed to keep closure alive

This commit is contained in:
gorhill 2016-03-06 21:27:28 -05:00
parent 040a3ea5ef
commit 7884cf70f6

View File

@ -50,6 +50,7 @@
let shutdown = function(ev) {
if ( ev.target === this ) {
this.removeEventListener('unload', shutdown);
locationChangeListener = null;
}
};
this.addEventListener('unload', shutdown);