1
0
mirror of https://github.com/gorhill/uBlock.git synced 2024-11-05 18:32:30 +01:00

Fail graciously if no benchmark dataset found

This commit is contained in:
Raymond Hill 2020-02-21 08:13:15 -05:00
parent b784b7d569
commit ddc2b11657
No known key found for this signature in database
GPG Key ID: 25E1490B761470C2

View File

@ -692,7 +692,8 @@
const datasetURL = µBlock.hiddenSettings.benchmarkDatasetURL;
if ( datasetURL === 'unset' ) {
return Promise.reject('No dataset');
console.info(`No benchmark dataset available.`);
return Promise.resolve();
}
console.info(`Loading benchmark dataset...`);
datasetPromise = µBlock.assets.fetchText(datasetURL).then(details => {