mirror of
https://github.com/gorhill/uBlock.git
synced 2024-09-02 17:19:38 +02:00
minor code review
This commit is contained in:
parent
9772e95046
commit
bb66d44bac
@ -164,7 +164,7 @@ vAPI.messaging = {
|
|||||||
if ( this.port !== null ) {
|
if ( this.port !== null ) {
|
||||||
if ( this.channelCount !== 0 || this.pendingCount !== 0 ) {
|
if ( this.channelCount !== 0 || this.pendingCount !== 0 ) {
|
||||||
this.portTimer = vAPI.setTimeout(this.portPollerCallback, this.portTimerDelay);
|
this.portTimer = vAPI.setTimeout(this.portPollerCallback, this.portTimerDelay);
|
||||||
this.portTimerDelay = Math.min(this.portTimerDelay * 2, 3600000);
|
this.portTimerDelay = Math.min(this.portTimerDelay * 2, 60 * 60 * 1000);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -218,7 +218,7 @@ vAPI.messaging = {
|
|||||||
port.onDisconnect.addListener(this.disconnectListenerCallback);
|
port.onDisconnect.addListener(this.disconnectListenerCallback);
|
||||||
} catch (ex) {
|
} catch (ex) {
|
||||||
}
|
}
|
||||||
this.portTimerDelay = 15000;
|
this.portTimerDelay = 10000;
|
||||||
if ( this.portTimer === null ) {
|
if ( this.portTimer === null ) {
|
||||||
this.portTimer = vAPI.setTimeout(this.portPollerCallback, this.portTimerDelay);
|
this.portTimer = vAPI.setTimeout(this.portPollerCallback, this.portTimerDelay);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user