Make the toolbar warning timeout configurable

Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/2589
This commit is contained in:
Raymond Hill 2023-04-14 09:55:06 -04:00
parent 7347a2148a
commit 19db4e57f2
No known key found for this signature in database
GPG key ID: 25E1490B761470C2
2 changed files with 2 additions and 1 deletions

View file

@ -82,6 +82,7 @@ const hiddenSettingsDefault = {
requestJournalProcessPeriod: 1000,
selfieAfter: 2,
strictBlockingBypassDuration: 120,
toolbarWarningTimeout: 60,
uiPopupConfig: 'unset',
uiStyles: 'unset',
updateAssetBypassBrowserCache: false,

View file

@ -1133,7 +1133,7 @@ const webRequest = {
urls: [ 'http://*/*', 'https://*/*' ]
}
);
vAPI.defer.once({ min: 1 }).then(( ) => {
vAPI.defer.once({ sec: µb.hiddenSettings.toolbarWarningTimeout }).then(( ) => {
if ( vAPI.net.hasUnprocessedRequest() === false ) { return; }
vAPI.net.removeUnprocessedRequest();
return vAPI.tabs.getCurrent();