Fix launch of auto update shortly after launch

Regression from:
https://github.com/gorhill/uBlock/commit/bd7ce41224
This commit is contained in:
Raymond Hill 2023-12-15 09:59:56 -05:00
parent b9476cfb6e
commit d56468b4ec
No known key found for this signature in database
GPG Key ID: 25E1490B761470C2
1 changed files with 5 additions and 1 deletions

View File

@ -474,7 +474,11 @@ lz4Codec.relinquish();
// https://github.com/chrisaljoudi/uBlock/issues/184 // https://github.com/chrisaljoudi/uBlock/issues/184
// Check for updates not too far in the future. // Check for updates not too far in the future.
io.addObserver(µb.assetObserver.bind(µb)); io.addObserver(µb.assetObserver.bind(µb));
µb.scheduleAssetUpdater(); µb.scheduleAssetUpdater({
updateDelay: µb.userSettings.autoUpdate
? µb.hiddenSettings.autoUpdateDelayAfterLaunch * 1000
: 0
});
// Force an update of the context menu according to the currently // Force an update of the context menu according to the currently
// active tab. // active tab.